mirror of
				https://github.com/node-red/node-red.git
				synced 2025-03-01 10:36:34 +00:00 
			
		
		
		
	Fix regular expression for Node.js v8
This commit is contained in:
		| @@ -31,7 +31,7 @@ RED.palette.editor = (function() { | ||||
|     var eventTimers = {}; | ||||
|     var activeFilter = ""; | ||||
|  | ||||
|     var semverre = /^(?<major>\d+)(\.(?<minor>\d+))?(\.(?<patch>\d+))?(-(?<pre>[0-9A-Za-z-]+))?(\.(?<build>[0-9A-Za-z-.]+))?$/; | ||||
|     var semverre = /^(\d+)(\.(\d+))?(\.(\d+))?(-([0-9A-Za-z-]+))?(\.([0-9A-Za-z-.]+))?$/; | ||||
|     var NUMBERS_ONLY = /^\d+$/; | ||||
|  | ||||
|     function SemVerPart(part) { | ||||
| @@ -61,8 +61,8 @@ RED.palette.editor = (function() { | ||||
|     }; | ||||
|  | ||||
|     function SemVer(ver) { | ||||
|         var groups = ver.match( semverre ).groups; | ||||
|         this.parts = [ new SemVerPart( groups.major ), new SemVerPart( groups.minor ), new SemVerPart( groups.patch ), new SemVerPart( groups.pre ), new SemVerPart( groups.build ) ]; | ||||
|         var groups = ver.match( semverre ); | ||||
|         this.parts = [ new SemVerPart( groups[1] ), new SemVerPart( groups[3] ), new SemVerPart( groups[5] ), new SemVerPart( groups[7] ), new SemVerPart( groups[9] ) ]; | ||||
|     } | ||||
|  | ||||
|     SemVer.prototype.compare = function(other) { | ||||
|   | ||||
		Reference in New Issue
	
	Block a user