Version Description
- Bug fixes for sites with no
administrator
role.
Download this release
Release Info
Developer | rpetersen29 |
Plugin | Simple Banner |
Version | 2.10.2 |
Comparing to | |
See all releases |
Code changes from version 2.10.1 to 2.10.2
- readme.txt +7 -1
- simple-banner.php +6 -4
readme.txt
CHANGED
@@ -4,7 +4,7 @@ Donate link: https://www.paypal.me/rpetersenDev
|
|
4 |
Tags: banner, simple, top, bar, announcement, top bar, topbar, bulletin, notification, notice, cta, free
|
5 |
Requires at least: 3.0.1
|
6 |
Tested up to: 5.7
|
7 |
-
Stable tag: 2.10.
|
8 |
License: GPLv2 or later
|
9 |
License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
10 |
|
@@ -118,6 +118,9 @@ Set your banner position to <code>relative</code> and try this in 'Website Custo
|
|
118 |
|
119 |
== Changelog ==
|
120 |
|
|
|
|
|
|
|
121 |
= 2.10.1 =
|
122 |
* Bug fixes. Remove some unnecessary script params.
|
123 |
|
@@ -268,6 +271,9 @@ Set your banner position to <code>relative</code> and try this in 'Website Custo
|
|
268 |
|
269 |
== Upgrade Notice ==
|
270 |
|
|
|
|
|
|
|
271 |
= 2.10.1 =
|
272 |
* Bug fixes. Remove some unnecessary script params.
|
273 |
|
4 |
Tags: banner, simple, top, bar, announcement, top bar, topbar, bulletin, notification, notice, cta, free
|
5 |
Requires at least: 3.0.1
|
6 |
Tested up to: 5.7
|
7 |
+
Stable tag: 2.10.2
|
8 |
License: GPLv2 or later
|
9 |
License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
10 |
|
118 |
|
119 |
== Changelog ==
|
120 |
|
121 |
+
= 2.10.2 =
|
122 |
+
* Bug fixes for sites with no `administrator` role.
|
123 |
+
|
124 |
= 2.10.1 =
|
125 |
* Bug fixes. Remove some unnecessary script params.
|
126 |
|
271 |
|
272 |
== Upgrade Notice ==
|
273 |
|
274 |
+
= 2.10.2 =
|
275 |
+
* Bug fixes for sites with no `administrator` role.
|
276 |
+
|
277 |
= 2.10.1 =
|
278 |
* Bug fixes. Remove some unnecessary script params.
|
279 |
|
simple-banner.php
CHANGED
@@ -3,16 +3,16 @@
|
|
3 |
* Plugin Name: Simple Banner
|
4 |
* Plugin URI: https://github.com/rpetersen29/simple-banner
|
5 |
* Description: Display a simple banner at the top of your website.
|
6 |
-
* Version: 2.10.
|
7 |
* Author: Ryan Petersen
|
8 |
* Author URI: http://rpetersen29.github.io/
|
9 |
* License: GPL2
|
10 |
*
|
11 |
* @package Simple Banner
|
12 |
-
* @version 2.10.
|
13 |
* @author Ryan Petersen <rpetersen.dev@gmail.com>
|
14 |
*/
|
15 |
-
define ('VERSION', '2.10.
|
16 |
|
17 |
register_activation_hook( __FILE__, 'simple_banner_activate' );
|
18 |
function simple_banner_activate() {
|
@@ -203,7 +203,9 @@ function simple_banner_menu() {
|
|
203 |
$manage_options = 'manage_options';
|
204 |
// Add admin access
|
205 |
$admin = get_role( 'administrator' );
|
206 |
-
$admin
|
|
|
|
|
207 |
|
208 |
$permissions_array = get_option('permissions_array');
|
209 |
|
3 |
* Plugin Name: Simple Banner
|
4 |
* Plugin URI: https://github.com/rpetersen29/simple-banner
|
5 |
* Description: Display a simple banner at the top of your website.
|
6 |
+
* Version: 2.10.2
|
7 |
* Author: Ryan Petersen
|
8 |
* Author URI: http://rpetersen29.github.io/
|
9 |
* License: GPL2
|
10 |
*
|
11 |
* @package Simple Banner
|
12 |
+
* @version 2.10.2
|
13 |
* @author Ryan Petersen <rpetersen.dev@gmail.com>
|
14 |
*/
|
15 |
+
define ('VERSION', '2.10.2');
|
16 |
|
17 |
register_activation_hook( __FILE__, 'simple_banner_activate' );
|
18 |
function simple_banner_activate() {
|
203 |
$manage_options = 'manage_options';
|
204 |
// Add admin access
|
205 |
$admin = get_role( 'administrator' );
|
206 |
+
if ($admin) {
|
207 |
+
$admin->add_cap( $manage_simple_banner );
|
208 |
+
}
|
209 |
|
210 |
$permissions_array = get_option('permissions_array');
|
211 |
|