Skip to content

Commit

Permalink
Merge pull request #232 from 10up/fix/filemonth_folders_issue
Browse files Browse the repository at this point in the history
fix issue with yearmonth folders option checked
  • Loading branch information
jeffpaul authored Jul 9, 2024
2 parents af2dc83 + 29170d8 commit 630c4b1
Show file tree
Hide file tree
Showing 2 changed files with 29 additions and 17 deletions.
40 changes: 23 additions & 17 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 6 additions & 0 deletions windows-azure-storage.php
Original file line number Diff line number Diff line change
Expand Up @@ -455,6 +455,12 @@ function windows_azure_storage_wp_generate_attachment_metadata( $data, $post_id
)
);

// Check if yearmonth_folders is checked
$user_filemonth_folders = get_option( 'uploads_use_yearmonth_folders' );
if ( empty( $user_filemonth_folders ) ) {
$upload_folder_path = '/';
}

try {
$post_array = wp_unslash( $_POST );
$post_array = wp_parse_args( $post_array, array(
Expand Down

0 comments on commit 630c4b1

Please sign in to comment.