1
0
mirror of https://github.com/gryf/pentadactyl-pm.git synced 2025-12-21 20:07:59 +01:00

always construct a default usage string for mappings and commands

This commit is contained in:
Doug Kearns
2007-07-13 15:01:47 +00:00
parent e0245fe575
commit 65ddc4a375
2 changed files with 8 additions and 8 deletions

View File

@@ -72,17 +72,15 @@ function Command(specs, action, extra_info) //{{{
this.action = action;
// TODO: build a better default usage string
this.usage = this.specs;
if (extra_info)
{
//var flags = extra_info.flags || 0;
if (extra_info.usage)
this.usage = extra_info.usage;
else
{
// TODO: build a default usage string -- djk
this.usage = this.name;
}
this.help = extra_info.help || null;
this.short_help = extra_info.short_help || null;