Warning: Illegal string offset ‘zerif_logo’ wordpress

I am working on WordPress V4.4.2 with the theme named Zerif lite theme. Everything working fine on local but on development server I am getting below error when updating any content by using Customising section.

Warning: Illegal string offset ‘zerif_logo’ in
/wp-includes/theme.php on line 901

Read More

Code is

function get_theme_mod( $name, $default = false ) {
    $mods = get_theme_mods();

    if ( isset( $mods[$name] ) ) {
        /**
         * Filter the theme modification, or 'theme_mod', value.
         *
         * The dynamic portion of the hook name, `$name`, refers to
         * the key name of the modification array. For example,
         * 'header_textcolor', 'header_image', and so on depending
         * on the theme options.
         *
         * @since 2.2.0
         *
         * @param string $current_mod The value of the current theme modification.
         */
        return apply_filters( "theme_mod_{$name}", $mods[$name] );
    }

    if ( is_string( $default ) )
        $default = sprintf( $default, get_template_directory_uri(), get_stylesheet_directory_uri() );

    /** This filter is documented in wp-includes/theme.php */
    return apply_filters( "theme_mod_{$name}", $default );
}

line 901 code is

return apply_filters( "theme_mod_{$name}", $mods[$name] );

EDIT

After Placing

$mods = get_theme_mods();
var_dump('content of $mods', $mods);

I get below data

string(16) “content of $mods” string(2208)
“h:22:{i:0;b:0;s:10:”zerif_logo”;s:68:”http://example.in/clinic/wp-content/uploads/2016/04/Caduceus.svg_.png“;s:11:”zerif_email”;s:24:”support@myclinictest.com”;s:13:”zerif_address”;s:22:”Jaipur
Rajasthan
India”;s:19:”zerif_bigtitle_show”;s:0:””;s:30:”zerif_bigtitle_redbutton_label”;s:7:”Contact”;s:32:”zerif_bigtitle_greenbutton_label”;s:11:”Appointment”;s:20:”zerif_ourfocus_title”;s:13:”Our
Specility”;s:23:”zerif_ourfocus_subtitle”;s:0:””;s:20:”zerif_bigtitle_title”;s:24:”You
Deserve Right Doctor”;s:22:”zerif_aboutus_subtitle”;s:122:…… so on

How can I fix this error.

Related posts