mirror of
https://github.com/lkddi/nexusphp.git
synced 2026-04-23 19:37:23 +08:00
improve login notify + migrate torrent purchase to announce
This commit is contained in:
@@ -13,14 +13,14 @@ class UserLoginNotify extends Command
|
||||
*
|
||||
* @var string
|
||||
*/
|
||||
protected $signature = 'user:login_notify {--this_id=} {--last_id=}';
|
||||
protected $signature = 'user:login_notify {--this_id=}';
|
||||
|
||||
/**
|
||||
* The console command description.
|
||||
*
|
||||
* @var string
|
||||
*/
|
||||
protected $description = 'Send login notify, option: --this_id, --last_id';
|
||||
protected $description = 'Send login notify, option: --this_id';
|
||||
|
||||
/**
|
||||
* Execute the console command.
|
||||
@@ -30,13 +30,12 @@ class UserLoginNotify extends Command
|
||||
public function handle()
|
||||
{
|
||||
$thisId = $this->option('this_id');
|
||||
$lastId = $this->option('last_id');
|
||||
$this->info("thisId: $thisId, lastId: $lastId");
|
||||
if (!$thisId || !$lastId) {
|
||||
$this->error("require option --this_id=? and --last_id=?");
|
||||
$this->info("thisId: $thisId");
|
||||
if (!$thisId) {
|
||||
$this->error("require option --this_id=?");
|
||||
return Command::FAILURE;
|
||||
}
|
||||
SendLoginNotify::dispatch($thisId, $lastId);
|
||||
SendLoginNotify::dispatch($thisId);
|
||||
return Command::SUCCESS;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user