Stripped the trailing vars

This commit is contained in:
Devine Lu Linvega 2017-11-15 16:39:07 +13:00
parent 5c7e5a1512
commit e1ff9358b5
3 changed files with 4 additions and 2 deletions

View File

@ -14,7 +14,6 @@ function Commander()
this.validate = function(q = ronin.commander.query())
{
console.info(q.string)
if(!ronin.modules[q.module]){ console.log("Unknown module",q.module); return; }
if(q.raw.indexOf("$") > -1){ console.log("Variables present"); return; }
if(q.raw.indexOf(";") > -1){ this.validate_multi(q); return; }

View File

@ -1,5 +1,8 @@
function Query(query_str = "")
{
// Strip trailing variables
query_str = query_str.indexOf("&$+") > -1 ? query_str.replace("&$+","").trim() : query_str
this.string = query_str;
this.module = query_str.split(" ")[0];
var parts = query_str.split(" ").splice(1);

View File

@ -2,7 +2,7 @@ function Path()
{
Module.call(this,"path","Trace lines and to draw shapes.");
this.settings = {thickness:4,color:"white",cap:"square"};
this.settings = {thickness:4,color:"red",cap:"square"};
this.methods.stroke = new Method("stroke","x,y&","",function(q){
ronin.preview.clear();