Skip to content

Commit 7583074

Browse files
committed
use queue_status
1 parent 8707ee5 commit 7583074

File tree

2 files changed

+3
-2
lines changed

2 files changed

+3
-2
lines changed

php/sync/class-sync-queue.php

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -101,7 +101,8 @@ public function setup() {
101101
* @return bool
102102
*/
103103
public function is_enabled() {
104-
return $this->is_running();
104+
$status = $this->get_queue_status();
105+
return $status['is_running'];
105106
}
106107

107108
/**

php/ui/component/class-sync.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ protected function status( $struct ) {
4545
$icon = 'dashicons-yes-alt';
4646
$state_text = __( 'All assets are synced', 'cloudinary' );
4747

48-
if ( ! empty( $to_sync ) && $this->setting->get_param( 'queue' )->is_enabled() ) {
48+
if ( $this->setting->get_param( 'queue' )->is_enabled() ) {
4949
$state = 'notification-syncing';
5050
$icon = 'dashicons-update';
5151
$state_text = __( 'Syncing now', 'cloudinary' );

0 commit comments

Comments
 (0)