| @@ -303,9 +303,11 @@ | ||
| 303 | 303 | $active_modules_by_id[ $data->id ] = true; |
| 304 | 304 | } |
| 305 | 305 | ?> |
| 306 | 306 | <tr<?php if ( $is_active ) { |
| 307 | - if ( $fs->has_api_connectivity() && $fs->is_on() ) { | |
| 307 | + $has_api_connectivity = $fs->has_api_connectivity(); | |
| 308 | + | |
| 309 | + if ( true === $has_api_connectivity && $fs->is_on() ) { | |
| 308 | 310 | echo ' style="background: #E6FFE6; font-weight: bold"'; |
| 309 | 311 | } else { |
| 310 | 312 | echo ' style="background: #ffd0d0; font-weight: bold"'; |
| 311 | 313 | } |
| @@ -313,14 +315,16 @@ | ||
| 313 | 315 | <td><?php echo $data->id ?></td> |
| 314 | 316 | <td><?php echo $slug ?></td> |
| 315 | 317 | <td><?php echo $data->version ?></td> |
| 316 | 318 | <td><?php echo $data->title ?></td> |
| 317 | - <td<?php if ( $is_active && ! $fs->has_api_connectivity() ) { | |
| 319 | + <td<?php if ( $is_active && true !== $has_api_connectivity ) { | |
| 318 | 320 | echo ' style="color: red; text-transform: uppercase;"'; |
| 319 | 321 | } ?>><?php if ( $is_active ) { |
| 320 | - echo esc_html( $fs->has_api_connectivity() ? | |
| 322 | + echo esc_html( true === $has_api_connectivity ? | |
| 321 | 323 | fs_text_x_inline( 'Connected', 'as connection was successful' ) : |
| 322 | - fs_text_x_inline( 'Blocked', 'as connection blocked' ) | |
| 324 | + ( false === $has_api_connectivity ? | |
| 325 | + fs_text_x_inline( 'Blocked', 'as connection blocked' ) : | |
| 326 | + fs_text_x_inline( 'Unknown', 'API connectivity state is unknown' ) ) | |
| 323 | 327 | ); |
| 324 | 328 | } ?></td> |
| 325 | 329 | <td<?php if ( $is_active && ! $fs->is_on() ) { |
| 326 | 330 | echo ' style="color: red; text-transform: uppercase;"'; |