File tree Expand file tree Collapse file tree 2 files changed +5
-5
lines changed Expand file tree Collapse file tree 2 files changed +5
-5
lines changed Original file line number Diff line number Diff line change 66
77class CannotCreateUser extends Exception
88{
9- public static function duplicateEmailAddress (string $ emailAddress ): CannotCreateUser
9+ public static function duplicateEmailAddress (string $ emailAddress ): self
1010 {
1111 return new static ("The email address [ $ emailAddress] already exists. " );
1212 }
1313
14- public static function duplicateUsername (string $ username ): CannotCreateUser
14+ public static function duplicateUsername (string $ username ): self
1515 {
1616 return new static ("The username [ $ username] already exists. " );
1717 }
Original file line number Diff line number Diff line change @@ -216,17 +216,17 @@ public function countSolutions(): int
216216 })->count ();
217217 }
218218
219- public static function findByUsername (string $ username ): User
219+ public static function findByUsername (string $ username ): self
220220 {
221221 return static ::where ('username ' , $ username )->firstOrFail ();
222222 }
223223
224- public static function findByEmailAddress (string $ emailAddress ): User
224+ public static function findByEmailAddress (string $ emailAddress ): self
225225 {
226226 return static ::where ('email ' , $ emailAddress )->firstOrFail ();
227227 }
228228
229- public static function findByGithubId (string $ githubId ): User
229+ public static function findByGithubId (string $ githubId ): self
230230 {
231231 return static ::where ('github_id ' , $ githubId )->firstOrFail ();
232232 }
You can’t perform that action at this time.
0 commit comments