Implement creator studio and upload updates
This commit is contained in:
@@ -55,6 +55,10 @@ class ArtworkObserver
|
||||
// The pivot sync happens outside this observer, so we dispatch on every
|
||||
// meaningful update and let the job be idempotent (cheap if nothing changed).
|
||||
if ($artwork->is_public && $artwork->published_at) {
|
||||
if ($artwork->wasChanged('published_at') || $artwork->wasChanged('created_at')) {
|
||||
$this->userStats->setLastUploadAt($artwork->user_id, $artwork->created_at ?? $artwork->published_at);
|
||||
}
|
||||
|
||||
RecComputeSimilarByTagsJob::dispatch($artwork->id)->delay(now()->addSeconds(30));
|
||||
RecComputeSimilarHybridJob::dispatch($artwork->id)->delay(now()->addMinutes(1));
|
||||
|
||||
|
||||
Reference in New Issue
Block a user