web-manager 3.2.2 → 3.2.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/lib/account.js +11 -3
  2. package/package.json +1 -1
package/lib/account.js CHANGED
@@ -160,12 +160,20 @@ function handlePlanVisibility(planId) {
160
160
 
161
161
  // Special case for '$paid'
162
162
  if (requiredPlans.includes('$paid')) {
163
- shouldBeVisible = (planId !== 'basic');
163
+ shouldBeVisible = planId !== 'basic';
164
164
  } else {
165
- shouldBeVisible = (requiredPlans.includes(planId));
165
+ shouldBeVisible = requiredPlans.includes(planId);
166
166
  }
167
167
 
168
- element.setAttribute('hidden', shouldBeVisible ? (visibility === 'hidden') : (visibility === 'visible'));
168
+ var shouldHide = shouldBeVisible
169
+ ? visibility === 'hidden'
170
+ : visibility === 'visible';
171
+
172
+ if (shouldHide) {
173
+ element.setAttribute('hidden', true);
174
+ } else {
175
+ element.removeAttribute('hidden');
176
+ }
169
177
  });
170
178
  }
171
179
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "web-manager",
3
- "version": "3.2.2",
3
+ "version": "3.2.3",
4
4
  "description": "Easily access important variables such as the query string, current domain, and current page in a single object.",
5
5
  "main": "index.js",
6
6
  "scripts": {