Skip to content

Commit

Permalink
Fix value of JS variable
Browse files Browse the repository at this point in the history
  • Loading branch information
bencroker committed May 3, 2024
1 parent 5b97d40 commit 8ca2d04
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 2 deletions.
6 changes: 6 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,11 @@
# Release Notes for Campaign

## 3.1.3 - 2024-05-03

### Fixed

- Fixed a bug in which non-admin users without permissions to edit segments were not seeing content ([#472](https://github.com/putyourlightson/craft-campaign/issues/472)).

## 3.1.2 - 2024-05-02

### Fixed
Expand Down
2 changes: 1 addition & 1 deletion composer.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "putyourlightson/craft-campaign",
"description": "Send and manage email campaigns, contacts and mailing lists.",
"version": "3.1.2",
"version": "3.1.3",
"type": "craft-plugin",
"homepage": "https://putyourlightson.com/plugins/campaign",
"license": "proprietary",
Expand Down
2 changes: 1 addition & 1 deletion src/assets/CpAsset.php
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@ private function registerEditableTypes(BaseView $view): void
$editableSendoutTypes = Json::encode($this->getEditableSendoutTypes());

$user = Craft::$app->getUser()->getIdentity();
$canEditSegments = $user->can('campaign:segments');
$canEditSegments = $user->can('campaign:segments') ? 'true' : 'false';

$js = <<<JS
window.Craft.editableCampaignTypes = $editableCampaignTypes;
Expand Down

0 comments on commit 8ca2d04

Please sign in to comment.