| 1 |
<?php |
| 2 |
/** |
| 3 |
* Utilities |
| 4 |
* |
| 5 |
* @package Unagi |
| 6 |
*/ |
| 7 |
|
| 8 |
namespace Unagi\Utils; |
| 9 |
|
| 10 |
/** |
| 11 |
* Determine displaying notifications nicely vs directly |
| 12 |
* When we show them "nicely" we parse the buffer and count notifications node from the dom |
| 13 |
* And we keep the count |
| 14 |
* |
| 15 |
* @return mixed|void |
| 16 |
* @since 0.1.0 |
| 17 |
*/ |
| 18 |
function show_notifications_nicely() { |
| 19 |
return apply_filters( 'unagi_show_notifications_nicely', true ); |
| 20 |
} |
| 21 |
|
| 22 |
/** |
| 23 |
* Min. required capability to use this plugin |
| 24 |
* |
| 25 |
* @return mixed|void |
| 26 |
* @since 0.1.0 |
| 27 |
*/ |
| 28 |
function required_capability() { |
| 29 |
return apply_filters( 'unagi_required_capability', 'edit_posts' ); |
| 30 |
} |
| 31 |
|