Skip to content
This repository was archived by the owner on Dec 17, 2024. It is now read-only.

Commit 8e8a499

Browse files
committed
fix for broken session help onclick
Fixes #726
1 parent 8bcac73 commit 8e8a499

File tree

2 files changed

+5
-4
lines changed

2 files changed

+5
-4
lines changed

app/content/js/usage-error.js

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -130,7 +130,8 @@ const format = (message, options={}) => {
130130

131131
const { command, docs, title, breadcrumb=title||command, header=docs&&`${docs}.`, example, detailedExample, sampleInputs,
132132
commandPrefix, commandPrefixNotNeeded,
133-
available, parents=[], related, required, optional, oneof } = usage
133+
available, parents=[], related, required, optional, oneof } = usage,
134+
outerCommandPrefix = commandPrefix
134135

135136
// the return value will be `result`; we will populate it with
136137
// those fields now; `body` is the flex-wrap portion of the
@@ -338,7 +339,7 @@ const format = (message, options={}) => {
338339

339340
// fields of the row model
340341
// debug('row', rowData)
341-
const { commandPrefix, command=commandPrefix, name=command, label=name,
342+
const { commandPrefix=outerCommandPrefix, command=commandPrefix, name=command, label=name,
342343
alias, numeric, aliases=[alias], hidden=false, advanced=false,
343344
available,
344345
example=numeric&&'N', dir:isDir=available||false,
@@ -358,7 +359,7 @@ const format = (message, options={}) => {
358359
docsPart = span(docs),
359360
allowedPart = allowed && smaller(span(undefined))
360361

361-
// for repl.exec,
362+
// for repl.exec,
362363
const commandForExec = alias => `${commandPrefix && !commandPrefixNotNeeded ? commandPrefix + ' ' : ''}${alias}`
363364

364365
row.className = 'log-line entity'

app/plugins/modules/composer/usage.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@ module.exports = {
4949
title: 'Inspecting Sessions',
5050
header: 'These commands will help you inspect the activation results of Composer applications.',
5151
example: 'wsk session <command>',
52-
commandPrefix: 'wsk session',
52+
commandPrefix: 'session',
5353
available: [{ command: 'get', docs: 'get the details of a given Composer activation' },
5454
{ command: 'list', docs: 'list recent Composer activations' }],
5555
parents: ['composer'],

0 commit comments

Comments
 (0)