Skip to content
This repository has been archived by the owner on Oct 18, 2022. It is now read-only.

Commit

Permalink
Fixes minor JavaScript bug; bump to 1.0.7
Browse files Browse the repository at this point in the history
  • Loading branch information
mmikkel committed Oct 1, 2016
1 parent 3f24838 commit c6e340a
Show file tree
Hide file tree
Showing 6 changed files with 21 additions and 7 deletions.
6 changes: 5 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Reasons v. 1.0.6 for Craft CMS ![Craft 2.5](https://img.shields.io/badge/craft-2.5-red.svg?style=flat-square)
# Reasons v. 1.0.7 for Craft CMS ![Craft 2.5](https://img.shields.io/badge/craft-2.5-red.svg?style=flat-square)

_Supercharge your field layouts with conditionals._

Expand Down Expand Up @@ -110,6 +110,10 @@ Please report any bugs, feature requests or other issues [here](https://github.c

### Changelog

#### 1.0.7 (10.01.2016)

* [Fixed] Fixes minor JavaScript bug (thanks @benf!)

#### 1.0.6 (07.10.2016)

* [Added] Support for the Button Box plugin fieldtypes as toggle fields
Expand Down
2 changes: 1 addition & 1 deletion reasons/ReasonsPlugin.php
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
class ReasonsPlugin extends BasePlugin
{

protected $_version = '1.0.6';
protected $_version = '1.0.7';
protected $_schemaVersion = '1.1';
protected $_developer = 'Mats Mikkel Rummelhoff';
protected $_developerUrl = 'http://mmikkel.no';
Expand Down

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion reasons/resources/rev-manifest.json
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
{
"javascripts/reasons.js": "javascripts/reasons-0722bebbde239c412f11.js",
"javascripts/reasons.js": "javascripts/reasons-77b7190892588775dd7e.js",
"stylesheets/reasons.css": "stylesheets/reasons-38f07b2161.css"
}
8 changes: 8 additions & 0 deletions releases.json
Original file line number Diff line number Diff line change
@@ -1,4 +1,12 @@
[
{
"version": "1.0.7",
"downloadUrl": "https://github.com/mmikkel/Reasons-Craft/archive/master.zip",
"date": "2016-10-01T10:00:00-08:00",
"notes": [
"[Fixed] Fixes minor JavaScript bug"
]
},
{
"version": "1.0.6",
"downloadUrl": "https://github.com/mmikkel/Reasons-Craft/archive/master.zip",
Expand Down
8 changes: 5 additions & 3 deletions source/javascripts/modules/render.js
Original file line number Diff line number Diff line change
Expand Up @@ -82,9 +82,11 @@ module.exports = class {
elementSelect;

$('[data-reasonselementselect]').each(function () {
elementSelect = $(this).elementSelect;
elementSelect.off('selectElements', self.onElementSelectChange.bind(self));
elementSelect.off('removeElements', self.onElementSelectChange.bind(self));
elementSelect = $(this).data('elementSelect');
if (elementSelect) {
elementSelect.off('selectElements', self.onElementSelectChange.bind(self));
elementSelect.off('removeElements', self.onElementSelectChange.bind(self));
}
$(this).removeAttr('[data-reasonselementselect]');
});

Expand Down

0 comments on commit c6e340a

Please sign in to comment.