Move all files to old/drupal/

This commit is contained in:
Oliver Davies 2025-10-02 07:57:25 +01:00
parent 8203e983d5
commit 7d76bf2968
468 changed files with 0 additions and 0 deletions

View file

@ -0,0 +1,22 @@
<?php
/**
* @file
* Install, update and uninstall functions for opdavies_blog.
*/
declare(strict_types=1);
use Drupal\opdavies_blog\Repository\PostRepository;
/**
* Mark existing blog posts as sent to social media.
*/
function opdavies_blog_update_8001(): void {
$posts = \Drupal::service(PostRepository::class)->getAll();
foreach ($posts as $post) {
$post->markAsSentToSocialMedia();
$post->save();
}
}