Skip to content

Commit 124ba15

Browse files
committed
Merge branch 'fix/effects-order' of cloudinary_wordpress:cloudinary/cloudinary_wordpress into fix/effects-order
2 parents 5cf7742 + 1a81ef6 commit 124ba15

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

php/connect/class-api.php

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -358,6 +358,10 @@ public function cloudinary_url( $public_id = null, $args = array(), $size = arra
358358
);
359359

360360
$base = Utils::pathinfo( $public_id );
361+
if ( ! empty( $args['transformation'] ) ) {
362+
$url_parts[] = self::generate_transformation_string( $args['transformation'], $args['resource_type'] );
363+
}
364+
361365
// Add size.
362366
if ( ! empty( $size ) && is_array( $size ) ) {
363367
if ( ! empty( $size['transformation'] ) ) {
@@ -368,9 +372,6 @@ public function cloudinary_url( $public_id = null, $args = array(), $size = arra
368372
$public_id = str_replace( $base['basename'], $size['file'], $public_id );
369373
}
370374
}
371-
if ( ! empty( $args['transformation'] ) ) {
372-
$url_parts[] = self::generate_transformation_string( $args['transformation'], $args['resource_type'] );
373-
}
374375

375376
if ( $attachment_id ) {
376377
$public_id = $this->get_public_id( $attachment_id, $args, $public_id );

0 commit comments

Comments
 (0)