@@ -175,7 +175,7 @@ public function clause($name)
175175 public function endpoint (Endpoint $ endpoint = null )
176176 {
177177 if ($ endpoint === null ) {
178- return $ this ->repository ();
178+ return $ this ->getRepository ();
179179 }
180180
181181 $ this ->repository ($ endpoint );
@@ -206,7 +206,7 @@ public function webservice(WebserviceInterface $webservice = null)
206206 */
207207 public function find ($ finder , array $ options = [])
208208 {
209- return $ this ->repository ()->callFinder ($ finder , $ this , $ options );
209+ return $ this ->getRepository ()->callFinder ($ finder , $ this , $ options );
210210 }
211211
212212 /**
@@ -224,7 +224,7 @@ public function firstOrFail()
224224 }
225225 throw new RecordNotFoundException (sprintf (
226226 'Record not found in endpoint "%s" ' ,
227- $ this ->repository ()->endpoint ()
227+ $ this ->getRepository ()->endpoint ()
228228 ));
229229 }
230230
@@ -466,12 +466,12 @@ public function first()
466466 public function triggerBeforeFind ()
467467 {
468468 if (!$ this ->_beforeFindFired && $ this ->action () === self ::ACTION_READ ) {
469- $ endpoint = $ this ->repository ();
469+ $ endpoint = $ this ->getRepository ();
470470 $ this ->_beforeFindFired = true ;
471471 $ endpoint ->dispatchEvent ('Model.beforeFind ' , [
472472 $ this ,
473473 new ArrayObject ($ this ->_options ),
474- !$ this ->eagerLoaded ()
474+ !$ this ->isEagerLoaded ()
475475 ]);
476476 }
477477 }
0 commit comments