Skip to content

Commit

Permalink
fix #253
Browse files Browse the repository at this point in the history
Only look for non empty users table instead of getting all users
  • Loading branch information
Cloverstone committed Aug 9, 2024
1 parent 2eda6ac commit 8ec8378
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
/vendor
/node_modules
/public/storage
/public/build
Homestead.yaml
Homestead.json
.env
Expand Down
4 changes: 2 additions & 2 deletions app/Libraries/CustomAuth.php
Original file line number Diff line number Diff line change
Expand Up @@ -31,9 +31,9 @@ public function authenticate(Request $request, $skip = false) {
if(!$skip && !$request->is('login*')){
return redirect('/login?redirect='.urlencode(URL::full()));
}else{

if(!$request->is('api/usersetup*')){
// return new Response();
if(!count(User::get())){
if(is_null(User::first()) ){
if(!$request->is('setup')){
return redirect('/setup');
}else{
Expand Down

0 comments on commit 8ec8378

Please sign in to comment.