]> scripts.mit.edu Git - autoinstalls/wordpress.git/blobdiff - wp-includes/bookmark.php
WordPress 4.2.5
[autoinstalls/wordpress.git] / wp-includes / bookmark.php
index 08b21297732fc17d9025f5ab4911dee1a1523868..47f5d233ab13d861c850da296e3ae394e5284bad 100644 (file)
@@ -386,17 +386,18 @@ function sanitize_bookmark_field($field, $value, $bookmark_id, $context) {
                } else {
                        $value = esc_attr($value);
                }
-       } else if ( 'db' == $context ) {
+       } elseif ( 'db' == $context ) {
                /** This filter is documented in wp-includes/post.php */
                $value = apply_filters( "pre_$field", $value );
        } else {
                /** This filter is documented in wp-includes/post.php */
                $value = apply_filters( $field, $value, $bookmark_id, $context );
 
-               if ( 'attribute' == $context )
-                       $value = esc_attr($value);
-               else if ( 'js' == $context )
-                       $value = esc_js($value);
+               if ( 'attribute' == $context ) {
+                       $value = esc_attr( $value );
+               } elseif ( 'js' == $context ) {
+                       $value = esc_js( $value );
+               }
        }
 
        return $value;