Commit 5ad56587 authored by xiaohua guan's avatar xiaohua guan Committed by Yas Naoi
Browse files

Issue #3163401 by Xiaohua Guan, yas: Fix a status message: "Cannot read...

Issue #3163401 by Xiaohua Guan, yas: Fix a status message: "Cannot read credentials from /.aws/credentials"
parent 0ac5fdee
Loading
Loading
Loading
Loading
+6
Changes for modules/cloud_service_providers/aws_cloud/aws_cloud.module: 6 added lines, 0 removed lines.
Original line number Diff line number Diff line
@@ -3722,6 +3722,12 @@ function aws_cloud_page_attachments(array &$attachments) {
 *   Private directory path.
 */
function aws_cloud_ini_directory() {
  $file_system = Drupal::service('file_system');
  if ($file_system->realpath(PrivateStream::basePath()) !== $file_system->realpath('private://')) {
    \Drupal::messenger()->addError(
      t('An error occurred getting private file directory. Please confirm whether the private file directory %directory exists.', ['%directory' => PrivateStream::basePath()])
    );
  }
  return 'private://aws_cloud/.aws';
}