Skip to content

Commit 6025f44

Browse files
committed
Merge pull request #2906 from JSteunou/patch-1
Remove use of deprecated $.selector
2 parents ab575c0 + fd44e21 commit 6025f44

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

src/region.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -112,7 +112,7 @@ const Region = MarionetteObject.extend({
112112
if (this.getOption('allowMissingEl')) {
113113
return false;
114114
} else {
115-
throw new MarionetteError('An "el" ' + this.$el.selector + ' must exist in DOM');
115+
throw new MarionetteError(`An "el" must exist in DOM for this region ${this.cid}`);
116116
}
117117
}
118118
return true;

test/unit/region.spec.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -79,7 +79,7 @@ describe('region', function() {
7979
it('should throw an exception saying an "el" doesnt exist in DOM', function() {
8080
expect(function() {
8181
this.region.show(new this.MyView());
82-
}.bind(this)).to.throw('An "el" #not-existed-region must exist in DOM');
82+
}.bind(this)).to.throw('An "el" must exist in DOM for this region ' + this.region.cid);
8383
});
8484

8585
it('should not have a view', function() {

0 commit comments

Comments
 (0)