PluginProbe
AcyMailing – An Ultimate Newsletter Plugin and Marketing Automation Solution for WordPress / 11.1.0
AcyMailing – An Ultimate Newsletter Plugin and Marketing Automation Solution for WordPress v11.1.0
11.1.1 11.1.0 11.0.5 11.0.4 11.0.3 11.0.2 11.0.1 11.0.0 10.11.1 10.11.0 10.10.2 10.10.1 10.10.0 10.9.1 trunk 10.0.0 10.0.1 10.1.0 10.1.1 10.1.2 10.1.3 10.1.4 10.2.0 10.2.1 10.2.2 All 62 releases
← All changes | back/Core/wordpress/user.php +4 -1 10.10.2 → 11.1.0 View file →
@@ -1,6 +1,8 @@
1 1 <?php
2 2
3 +defined('ABSPATH') || die('Restricted Access');
4 +
3 5 use AcyMailing\Core\AcymPunycode;
4 6
5 7 global $acymCmsUserVars;
6 8 $acymCmsUserVars = new stdClass();
@@ -19,9 +21,9 @@
19 21 } else {
20 22 $user = new WP_User($userid);
21 23 }
22 24
23 - if (is_multisite() && is_super_admin()) {
25 + if (is_multisite() && is_super_admin($user->ID)) {
24 26 return ['administrator'];
25 27 }
26 28
27 29 return $user->roles;
@@ -107,8 +109,9 @@
107 109 function acym_replaceGroupTags(string $uploadFolder): string
108 110 {
109 111 if (strpos($uploadFolder, '{groupname}') === false) return $uploadFolder;
110 112
113 + // Get user groups
111 114 $groups = acym_getGroupsByUser(acym_currentUserId());
112 115 $group = array_shift($groups);
113 116
114 117 $uploadFolder = str_replace(