diff --git a/app/Console/Commands/Admin/EmojiMoveStorageLocalToCloud.php b/app/Console/Commands/Admin/EmojiMoveStorageLocalToCloud.php index 22e53a933..535a95130 100644 --- a/app/Console/Commands/Admin/EmojiMoveStorageLocalToCloud.php +++ b/app/Console/Commands/Admin/EmojiMoveStorageLocalToCloud.php @@ -36,7 +36,12 @@ class EmojiMoveStorageLocalToCloud extends Command public function handle(): int { - if (! (bool) config_cache('pixelfed.cloud_storage')) { + // Consider cloud enabled if either the live config or the (possibly + // 12h-cached) config_cache value says so, so a stale cache can't make + // this silently no-op right after cloud is turned on. + $cloudEnabled = (bool) config('pixelfed.cloud_storage') || (bool) config_cache('pixelfed.cloud_storage'); + + if (! $cloudEnabled) { $this->error('Cloud storage is not enabled (pixelfed.cloud_storage is false).'); return self::FAILURE; diff --git a/database/migrations/2026_08_30_050000_migrate_local_emoji_to_cloud.php b/database/migrations/2026_08_30_050000_migrate_local_emoji_to_cloud.php index 68be1c270..8df4910e4 100644 --- a/database/migrations/2026_08_30_050000_migrate_local_emoji_to_cloud.php +++ b/database/migrations/2026_08_30_050000_migrate_local_emoji_to_cloud.php @@ -15,7 +15,11 @@ return new class extends Migration */ public function up(): void { - if (! (bool) config_cache('pixelfed.cloud_storage')) { + // Consider cloud enabled if either the live config or the (possibly + // cached) config_cache value says so; the command guards again anyway. + $cloudEnabled = (bool) config('pixelfed.cloud_storage') || (bool) config_cache('pixelfed.cloud_storage'); + + if (! $cloudEnabled) { return; } diff --git a/resources/views/admin/custom-emoji/duplicates.blade.php b/resources/views/admin/custom-emoji/duplicates.blade.php index 51ff3a714..678175e94 100644 --- a/resources/views/admin/custom-emoji/duplicates.blade.php +++ b/resources/views/admin/custom-emoji/duplicates.blade.php @@ -28,7 +28,7 @@
- +

{{ $emoji->shortcode }}

@@ -62,7 +62,7 @@ @foreach($emojis as $emoji)
- +

{{ $emoji->shortcode }}

diff --git a/resources/views/admin/custom-emoji/home.blade.php b/resources/views/admin/custom-emoji/home.blade.php index 54ac5886e..cfd746a35 100644 --- a/resources/views/admin/custom-emoji/home.blade.php +++ b/resources/views/admin/custom-emoji/home.blade.php @@ -105,7 +105,7 @@ @foreach($emojis as $emoji)
- +

{{ $emoji->shortcode }}