Skip to content

Commit c07eb35

Browse files
fix: update destructuring
1 parent d99fbd4 commit c07eb35

File tree

1 file changed

+2
-10
lines changed

1 file changed

+2
-10
lines changed

assets/src/dashboard/parts/connected/OptimizationStatus.js

Lines changed: 2 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -7,14 +7,10 @@ import { closeSmall, check } from '@wordpress/icons';
77
import { useSelect } from '@wordpress/data';
88

99
const OptimizationStatus = () => {
10-
const {
11-
statuses
12-
} = useSelect( select => {
10+
const statuses = useSelect( select => {
1311
const { getSiteSettings } = select( 'optimole' );
14-
1512
const siteSettings = getSiteSettings();
16-
17-
const statuses = [
13+
return [
1814
{
1915
active: 'enabled' === siteSettings?.image_replacer,
2016
label: optimoleDashboardApp.strings.optimization_status.statusTitle1,
@@ -31,10 +27,6 @@ const OptimizationStatus = () => {
3127
description: optimoleDashboardApp.strings.optimization_status.statusSubTitle3
3228
}
3329
];
34-
35-
return {
36-
statuses: statuses
37-
};
3830
});
3931

4032
return (

0 commit comments

Comments
 (0)