| @@ -22,9 +22,9 @@ | ||
| 22 | 22 | * @since 2.0.6 |
| 23 | 23 | * @access public |
| 24 | 24 | */ |
| 25 | 25 | public function define_message() { |
| 26 | - $this->message = sprintf( __( 'It seems your are using %1$sJetpack%2$s with site accelerator option enabled for images. %3$s To avoid any possible conflicts with Optimole replacement mechanism, you can go to %4$sJetpack -> Perfomance%5$s and turn off the site accelerator option for %6$simages%7$s ', 'optimole-wp' ), '<b>', '</b>', '<br/>', '<a target="_blank" href="' . admin_url( 'admin.php?page=jetpack#/performance' ) . '">', '</a>', '<b>', '</b>' ); | |
| 26 | + $this->message = sprintf( /* translators: 1 is the start of the bold tag, 2 is ending bold tag, 3 is new line tag, 4 is anchor tag start, 5 is ending anchor tag, 6 is start of bold tag, 7 is ending bold tag */ __( 'It seems your are using %1$sJetpack%2$s with site accelerator option enabled for images. %3$s To avoid any possible conflicts with Optimole replacement mechanism, you can go to %4$sJetpack -> Perfomance%5$s and turn off the site accelerator option for %6$simages%7$s', 'optimole-wp' ), '<b>', '</b>', '<br/>', '<a target="_blank" href="' . admin_url( 'admin.php?page=jetpack#/performance' ) . '">', '</a>', '<b>', '</b>' ); | |
| 27 | 27 | } |
| 28 | 28 | |
| 29 | 29 | /** |
| 30 | 30 | * Determine if conflict is applicable. |
| @@ -33,15 +33,9 @@ | ||
| 33 | 33 | * @since 2.0.6 |
| 34 | 34 | * @access public |
| 35 | 35 | */ |
| 36 | 36 | public function is_conflict_valid() { |
| 37 | + $compatibility = new Optml_jetpack_photon_compatibility(); | |
| 37 | 38 | |
| 38 | - if ( ! is_plugin_active( 'jetpack/jetpack.php' ) ) { | |
| 39 | - return false; | |
| 40 | - } | |
| 41 | - if ( ! class_exists( 'Jetpack', false ) ) { | |
| 42 | - return false; | |
| 43 | - } | |
| 44 | - | |
| 45 | - return Jetpack::is_module_active( 'photon' ); | |
| 39 | + return $compatibility->should_load(); | |
| 46 | 40 | } |
| 47 | 41 | } |