Merge pull request #500 from matrix-org/dbkr/linkify_fail_fast

Fail hard & fast if linkifyjs version is wrong
pull/21833/head
Richard van der Hoff 2016-09-27 11:29:39 +01:00 committed by GitHub
commit e403bcd770
1 changed files with 3 additions and 0 deletions

View File

@ -22,6 +22,9 @@ function matrixLinkify(linkify) {
var MultiToken = MT.Base; var MultiToken = MT.Base;
var S_START = linkify.parser.start; var S_START = linkify.parser.start;
if (TT.UNDERSCORE === undefined) {
throw new Error("linkify-matrix requires linkifyjs 2.1.1: this version is too old.");
}
var ROOMALIAS = function(value) { var ROOMALIAS = function(value) {
MultiToken.call(this, value); MultiToken.call(this, value);