From 08eea5840b31ea279ad2ff50a49b25748f3953d0 Mon Sep 17 00:00:00 2001 From: Vlad Olaru Date: Mon, 4 Nov 2019 09:08:59 +0200 Subject: [PATCH] Prevent showing header menu fallback link when user not logged in or doesn't have the required capabilities - version 1.0.3 --- assets/scss/style.scss | 6 +++--- inc/template-tags.php | 4 ++++ readme.txt | 11 +++++++---- style-rtl.css | 6 +++--- style.css | 6 +++--- 5 files changed, 20 insertions(+), 13 deletions(-) diff --git a/assets/scss/style.scss b/assets/scss/style.scss index d2368ac6..3c891d41 100644 --- a/assets/scss/style.scss +++ b/assets/scss/style.scss @@ -4,14 +4,14 @@ Theme URI: https://github.com/pixelgrade/rosa-lite Author: Pixelgrade Author URI: https://pixelgrade.com Description: This is the free version of Rosa, the #1 best selling restaurant WordPress theme, built to help small businesses shape an appealing online experience. It's packed with a parallax effect to grab attention, an online food menu so people can discover your offering, an easy to customize interface without using code, and a responsive design to address people on the go. This theme's versatility allows it to be used in a wide range of industries, making it the perfect theme if you own a business. No matter if it's a restaurant, beauty salon, house rental, hotel, coffee shop, or any other type of small business, this theme will fit your needs perfectly. -Version: 1.0.2 +Version: 1.0.3 License: GNU General Public License v3 License URI: http://www.gnu.org/licenses/gpl-3.0.html Text Domain: rosa-lite Tags: food-and-drink, two-columns, right-sidebar, custom-menu, featured-images, translation-ready, threaded-comments, rtl-language-support, custom-logo, editor-style -Requires PHP: 5.3.0 +Requires PHP: 5.4.0 Requires at least: 4.9.9 -Tested up to: 5.2.4 +Tested up to: 5.3.0 Rosa Lite WordPress Theme, Copyright (C) 2015-2019, Pixelgrade. Rosa Lite is distributed under the terms of the GNU GPL v3. diff --git a/inc/template-tags.php b/inc/template-tags.php index c693a11b..e2547e4e 100644 --- a/inc/template-tags.php +++ b/inc/template-tags.php @@ -77,6 +77,10 @@ function rosa_lite_the_archive_title() { if ( ! function_exists( 'rosa_lite_please_select_a_menu_fallback' ) ) { function rosa_lite_please_select_a_menu_fallback() { + if ( ! current_user_can( 'edit_theme_options' ) ) { + return; + } + echo '