Warning: Array to string conversion in /home/customer/www/docs.automatorplugin.com/public_html/wp-content/themes/wporg-developer/inc/template-tags.php on line 825
Warning: foreach() argument must be of type array|object, string given in /home/customer/www/docs.automatorplugin.com/public_html/wp-content/themes/wporg-developer/inc/template-tags.php on line 830
Warning: Array to string conversion in /home/customer/www/docs.automatorplugin.com/public_html/wp-content/themes/wporg-developer/inc/template-tags.php on line 825
Automator_DB::is_view_exists( $type = 'recipe' )
Check if specific VIEW is missing.
Warning: foreach() argument must be of type array|object, string given in /home/customer/www/docs.automatorplugin.com/public_html/wp-content/themes/wporg-developer/inc/template-tags.php on line 830
Warning: Array to string conversion in /home/customer/www/docs.automatorplugin.com/public_html/wp-content/themes/wporg-developer/inc/template-tags.php on line 825
Parameters Parameters
- $type
(Optional)
Default value: 'recipe'
Return Return
(bool)
Source Source
File: src/core/class-automator-db.php
public static function is_view_exists( string $type = 'recipe' ) { global $wpdb; $recipe_view = ''; if ( 'recipe' === $type ) { $recipe_view = "{$wpdb->prefix}uap_recipe_logs_view"; } if ( 'trigger' === $type ) { $recipe_view = "{$wpdb->prefix}uap_trigger_logs_view"; } if ( 'action' === $type ) { $recipe_view = "{$wpdb->prefix}uap_action_logs_view"; } if ( empty( $recipe_view ) ) { return false; } $results = self::all_views( true ); if ( ! in_array( $recipe_view, $results, true ) ) { return true; } return false; }
Expand full source code Collapse full source code View on Github