From b23cbdc59788acfa9aee12d7ff0131a8eaca2c1c Mon Sep 17 00:00:00 2001 From: Thomas Kluyver Date: Mon, 11 Dec 2017 16:45:01 +0000 Subject: [PATCH] Don't try to translate missing help strings Closes gh-3074 --- notebook/static/notebook/js/commandpalette.js | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/notebook/static/notebook/js/commandpalette.js b/notebook/static/notebook/js/commandpalette.js index 9ef218318..852f0f48d 100644 --- a/notebook/static/notebook/js/commandpalette.js +++ b/notebook/static/notebook/js/commandpalette.js @@ -157,6 +157,11 @@ define([ } else { display_text = humanize_action_id(action_id); } + + var help = null; + if (action.help) { + help = i18n.msg._(action.help); + } src[group].data.push({ display: display_text, @@ -164,7 +169,7 @@ define([ mode_shortcut: get_mode_for_action_id(action_id, notebook), group: group, icon: action.icon, - help: i18n.msg._(action.help), + help: help, key: action_id, }); }