mirror of
https://github.com/invoiceninja/invoiceninja.git
synced 2025-05-24 02:14:21 -04:00
Add checks for oauth provider id
This commit is contained in:
parent
f557a93533
commit
24cfda9b18
@ -29,6 +29,7 @@ use App\Models\Payment;
|
||||
use App\Models\Paymentable;
|
||||
use App\Models\QuoteInvitation;
|
||||
use App\Models\RecurringInvoiceInvitation;
|
||||
use App\Models\User;
|
||||
use App\Models\Vendor;
|
||||
use App\Utils\Ninja;
|
||||
use Exception;
|
||||
@ -115,7 +116,8 @@ class CheckData extends Command
|
||||
$this->checkCompanyData();
|
||||
$this->checkBalanceVsPaidStatus();
|
||||
$this->checkDuplicateRecurringInvoices();
|
||||
|
||||
$this->checkOauthSanity();
|
||||
|
||||
if(Ninja::isHosted())
|
||||
$this->checkAccountStatuses();
|
||||
|
||||
@ -146,6 +148,15 @@ class CheckData extends Command
|
||||
$this->log .= $str."\n";
|
||||
}
|
||||
|
||||
private function checkOauthSanity()
|
||||
{
|
||||
User::where('oauth_provider_id', '1')->cursor()->each(function ($user){
|
||||
|
||||
$this->logMessage("Invalid provider ID for user id# {$user->id}");
|
||||
|
||||
});
|
||||
}
|
||||
|
||||
private function checkDuplicateRecurringInvoices()
|
||||
{
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user