public ActionResult <Knights> GetByCastleId(int id) { try { return(Ok(_kservice.GetByCastleId(id))); } catch (Exception e) { return(BadRequest(e.Message)); } }
public ActionResult <IEnumerable <Knight> > GetKnights(int id) { try { return(Ok(_ks.GetByCastleId(id))); } catch (Exception e) { return(BadRequest(e.Message)); } }