nl_tokens: Helper function for checking expected plugin IDs against reality .
pl_tokens: function checkID ( expectedIdAndVersion , pinfo ) { if ( ! expectedIdAndVersion ) return ; var parsedSpec = pluginSpec . parse ( expectedIdAndVersion ) ; if ( parsedSpec . id !== pinfo . id ) { throw new Error ( 'Expected plugin to have ID "' + parsedSpec . id + '" but got "' + pinfo . id + '".' ) ; } if ( parsedSpec . version && ! semver . satisfies ( pinfo . version , parsedSpec . version ) ) { throw <mask> Error ( 'Expected plugin ' + pinfo . id + ' to satisfy version "' + parsedSpec . version + '" but got "' + pinfo . version + '".' ) ; } }