Bluesky/Tumblr: Set "received" to "created" if fetched after previous poll

This commit is contained in:
Michael 2023-12-20 20:46:24 +00:00
parent f32c90dc9f
commit 96a354bc65
5 changed files with 65 additions and 54 deletions

View file

@ -6,11 +6,11 @@ function bluesky_notifications_run($argv, $argc)
{
require_once 'addon/bluesky/bluesky.php';
if ($argc != 2) {
if ($argc != 3) {
return;
}
Logger::notice('importing notifications - start', ['user' => $argv[1]]);
bluesky_fetch_notifications($argv[1]);
Logger::notice('importing notifications - done', ['user' => $argv[1]]);
Logger::notice('importing notifications - start', ['user' => $argv[1], 'last_poll' => $argv[2]]);
bluesky_fetch_notifications($argv[1], $argv[2]);
Logger::notice('importing notifications - done', ['user' => $argv[1], 'last_poll' => $argv[2]]);
}