Skip to content

Commit

Permalink
Put file into public root, not /files
Browse files Browse the repository at this point in the history
  • Loading branch information
JacobSanford committed Sep 19, 2024
1 parent 877e234 commit 69de50a
Showing 1 changed file with 5 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,11 @@ public function attachFindingAidRecords(MigratePostRowSaveEvent $event) {
continue;
}
$file_components = pathinfo($file_path);
$uri_directory = 'public:/'. $file_components['dirname'];
$uri_directory = 'public:/'. str_replace(
'/files',
'',
$file_components['dirname']
);
$full_uri = $uri_directory . '/' . $file_components['basename'];

$file_system = \Drupal::service('file_system');
Expand Down

0 comments on commit 69de50a

Please sign in to comment.