Fix Purge Cache menu caching issue in the front-end #173
I have fixed the Purge Cache menu caching issue in front-end.
The text was updated successfully, but these errors were encountered:
… value on front-end admin bar. Conditionally display the purge cache button name as 'Purge Cache' for admin dashboard and 'Purge Current Page' on front-end admin bar. Conditionally set query argument 'nginx_helper_urls' value to 'all' for admin dashaboard purge cache button and 'current-url' for front-end admin bar button
Change hook from 'admin_init' to 'admin_bar_init' so that purge_all() is called when purge button is clicked on both admin dashboard and front end admin bar. Check if the user is on front end when set the call purge_url() and purge the current page cache on case basis.
Put the correct value for the 'meta key' of add_menu() and remove escaping from purge_url() on line 688 as already escaped at the end