Skip to content

Commit

Permalink
Add an array unique
Browse files Browse the repository at this point in the history
  • Loading branch information
bordoni committed Jun 12, 2024
1 parent ef87d41 commit f41f806
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/Assets/Asset.php
Original file line number Diff line number Diff line change
Expand Up @@ -939,6 +939,8 @@ public function maybe_get_min_file( $url ) {
$urls[] = $relative_location;
}

$urls = array_unique( $urls );

// Check for all Urls added to the array.
foreach ( $urls as $partial_path ) {
$file_path = wp_normalize_path( "{$base_dir}/{$partial_path}" );
Expand Down

0 comments on commit f41f806

Please sign in to comment.