Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
verify(options) {
let messages = [];
let pendingStatus = this.statusForModule('pending', options.moduleId);
let shouldIgnore = this.statusForModule('ignore', options.moduleId);
if (shouldIgnore) {
return messages;
}
let source = stripBom(options.source);
let templateAST;
try {
templateAST = parse(source);
} catch (error) {
let message = buildErrorMessage(options.moduleId, error);
messages.push(message);
}
let rules = this.buildRules({
results: messages,
pending: pendingStatus,
moduleId: options.moduleId,
moduleName: options.moduleId,
configResolver: options.configResolver,
rawSource: source,
});
for (let rule of rules) {
try {