public function update($newInstance, $oldInstance)
    {
        $instance = [];
        $instance['title'] = (!empty($newInstance['title']))
            ? strip_tags($newInstance['title']) : '';
        return $instance;
    }
public function update($newInstance, $oldInstance)
    {
        $instance = [];
        $instance['title'] = (!empty($newInstance['title']))
            ? strip_tags($newInstance['title']) : '';
        return $instance;
    }
public function update ( $ newInstance , $ oldInstance ) { $ instance = [ ] ; $ instance [ 'title' ] = ( ! empty ( $ newInstance [ 'title' ] ) ) ? strip_tags ( $ newInstance [ 'title' ] ) : '' ; return $ instance ; }
Updating widget replacing old instances with new.

@param array $newInstance
@param array $oldInstance
@return array

@see https://codex.wordpress.org/Widgets_API
Updating widget replacing old instances with new .