mirror of
https://github.com/discourse/discourse.git
synced 2024-11-26 02:40:53 -06:00
Merge pull request #2540 from codetaylor/master
BUGFIX: exception validating 'data-' attributes
This commit is contained in:
commit
09924da60b
@ -28,7 +28,7 @@ function validateAttribute(tagName, attribName, value) {
|
||||
// data-* attributes
|
||||
if (tag) {
|
||||
var allowed = tag[attribName] || tag['data-*'];
|
||||
if (allowed === value || allowed.indexOf('*') !== -1) { return value; }
|
||||
if (allowed && (allowed === value || allowed.indexOf('*') !== -1)) { return value; }
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user