Fix For Warning Errors In Update To 4.2
-
Ok so quite a few people have updated and noticed the warning error message in the wp admin (not displayed on the front end), so I did a little digging in the code and found it to be an easy fix that anyone could do if they want the warning messages gone before techotronic releases an update to fix it.
Simply head to the file in the warning and change the following lines of code from:
'frontendICO' => _('ICO',AIOFAVICON_TEXTDOMAIN), 'frontendGIF' => _('GIF',AIOFAVICON_TEXTDOMAIN), 'frontendPNG' => _('PNG',AIOFAVICON_TEXTDOMAIN), 'frontendApple' => _('Apple Touch Icon',AIOFAVICON_TEXTDOMAIN) ); //mapping of favicon types to translatable Strings $this->aioFaviconBackendMap = array( 'backendICO' => _('ICO',AIOFAVICON_TEXTDOMAIN), 'backendGIF' => _('GIF',AIOFAVICON_TEXTDOMAIN), 'backendPNG' => _('PNG',AIOFAVICON_TEXTDOMAIN), 'backendApple' => _('Apple Touch Icon',AIOFAVICON_TEXTDOMAIN)
Change to:
'frontendICO' => __('ICO',AIOFAVICON_TEXTDOMAIN), 'frontendGIF' => __('GIF',AIOFAVICON_TEXTDOMAIN), 'frontendPNG' => __('PNG',AIOFAVICON_TEXTDOMAIN), 'frontendApple' => __('Apple Touch Icon',AIOFAVICON_TEXTDOMAIN) ); //mapping of favicon types to translatable Strings $this->aioFaviconBackendMap = array( 'backendICO' => __('ICO',AIOFAVICON_TEXTDOMAIN), 'backendGIF' => __('GIF',AIOFAVICON_TEXTDOMAIN), 'backendPNG' => __('PNG',AIOFAVICON_TEXTDOMAIN), 'backendApple' => __('Apple Touch Icon',AIOFAVICON_TEXTDOMAIN)
All that I have done is added an extra _ to each line (changing each _ to _e would also work, but I thought adding another _ looked easier to the eye when checking over the code in the future), which fixes the problem and will stop displaying the warnings ??
https://www.ads-software.com/extend/plugins/all-in-one-favicon/
- The topic ‘Fix For Warning Errors In Update To 4.2’ is closed to new replies.