Plugin Directory

Changeset 2221716


Ignore:
Timestamp:
01/03/2020 04:49:07 PM (6 years ago)
Author:
jtroynousky
Message:

Patch that fixes a PHP warning and mismatches between image and window protocol.

Location:
image-compositions/trunk
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • image-compositions/trunk/assets/js/admin.js

    r2221685 r2221716  
    185185                    image.src = attachment.url;
    186186
    187                     // Ensure https.
    188                     image.src = image.src.replace( 'http:', 'https:' );
     187                    // Ensure image src matches window protocol.
     188                    var protocol = window.location.protocol,
     189                        url      = new URL( image.src );
     190
     191                    image.src = protocol + '//' + url.hostname + url.pathname;
    189192
    190193                    $image.css({
  • image-compositions/trunk/image-compositions.php

    r2221685 r2221716  
    534534
    535535            // Make sure nonce is set
    536             if ( ! wp_verify_nonce( $_POST['mdt-image-composition'], 'mdt-image-composition' ) ) {
     536            if ( ! isset( $_POST['mdt-image-composition'] ) || ! wp_verify_nonce( $_POST['mdt-image-composition'], 'mdt-image-composition' ) ) {
    537537                return;
    538538            }
  • image-compositions/trunk/readme.txt

    r2221685 r2221716  
    44Requires at least: 4.6
    55Tested up to: 5.3
    6 Stable tag: 1.0
     6Stable tag: 1.01
    77Requires PHP: 7.0
    88License: GPLv2 or later
     
    1717== Upgrade Notice ==
    1818
     19= 1.01 =
     20* Patch that fixes a PHP warning and mismatches between image and window protocol.
     21
    1922= 1.0 =
    2023* Initial plugin version
Note: See TracChangeset for help on using the changeset viewer.