PluginProbe
Formidable Forms – WordPress Form Builder for Contact Forms, Calculators, Quizzes & More / trunk
Formidable Forms – WordPress Form Builder for Contact Forms, Calculators, Quizzes & More vtrunk
6.35 6.34 6.33.1 6.33 6.32.1 6.32 6.31 6.25 6.25.1 6.26 6.26.1 6.27 6.28 6.29 6.3 6.3.1 6.3.2 6.30 6.4 6.4.1 6.4.2 6.5 6.5.1 6.5.2 6.5.3 All 141 releases
← All changes | classes/helpers/FrmShortcodeHelper.php +3 -8 6.28 → trunk View file →
@@ -23,13 +23,9 @@
23 23 if ( $text !== '' ) {
24 24 $atts = shortcode_parse_atts( $text );
25 25 }
26 26
27 - if ( ! is_array( $atts ) ) {
28 - return array();
29 - }
30 -
31 - return $atts;
27 + return is_array( $atts ) ? $atts : array();
32 28 }
33 29
34 30 /**
35 31 * Returns shortcodes that are shown/hidden based on the context.
@@ -72,12 +68,11 @@
72 68 *
73 69 * @return array
74 70 */
75 71 public static function get_contextual_codes() {
76 - $contextual_shortcodes = self::get_contextual_shortcodes();
77 - $result = array();
72 + $result = array();
78 73
79 - foreach ( $contextual_shortcodes as $type => $shortcodes ) {
74 + foreach ( self::get_contextual_shortcodes() as $type => $shortcodes ) {
80 75 $result[ $type ] = array_keys( $shortcodes );
81 76 }
82 77
83 78 return $result;