| @@ -3,11 +3,11 @@ | ||
| 3 | 3 | |
| 4 | 4 | /** |
| 5 | 5 | * Close an Imagify notice. |
| 6 | 6 | */ |
| 7 | - $( '.imagify-notice-dismiss' ).on( 'click.imagify', function( e ) { | |
| 7 | + $(document).on('click', '.imagify-notice-dismiss', function ( e ) { | |
| 8 | 8 | var $this = $( this ), |
| 9 | - $parent = $this.parents( '.imagify-welcome, .imagify-notice, .imagify-rkt-notice' ), | |
| 9 | + $parent = $this.parents( '.imagify-welcome, .imagify-notice, .imagify-rkt-notice, .imagify-upsell, .imagify-upsell-admin-bar' ), | |
| 10 | 10 | href = $this.attr( 'href' ); |
| 11 | 11 | |
| 12 | 12 | e.preventDefault(); |
| 13 | 13 | |
| @@ -44,9 +44,9 @@ | ||
| 44 | 44 | showLoaderOnConfirm: true, |
| 45 | 45 | customClass: 'imagify-sweet-alert imagify-sweet-alert-signup', |
| 46 | 46 | inputValidator: function( inputValue ) { |
| 47 | 47 | return new Promise( function( resolve, reject ) { |
| 48 | - if ( $.trim( inputValue ) === '' || ! inputValue ) { | |
| 48 | + if ( String( inputValue ).trim() === '' || ! inputValue ) { | |
| 49 | 49 | reject( imagifyNotices.labels.signupErrorEmptyEmail ); |
| 50 | 50 | } else { |
| 51 | 51 | resolve(); |
| 52 | 52 | } |
| @@ -93,9 +93,9 @@ | ||
| 93 | 93 | showLoaderOnConfirm: true, |
| 94 | 94 | customClass: 'imagify-sweet-alert imagify-sweet-alert-signup', |
| 95 | 95 | inputValidator: function( inputValue ) { |
| 96 | 96 | return new Promise( function( resolve, reject ) { |
| 97 | - if ( $.trim( inputValue ) === '' || ! inputValue ) { | |
| 97 | + if ( String( inputValue ).trim() === '' || ! inputValue ) { | |
| 98 | 98 | reject( imagifyNotices.labels.ApiKeyErrorEmpty ); |
| 99 | 99 | } else { |
| 100 | 100 | resolve(); |
| 101 | 101 | } |