(commandFn, options = {})
| 1271 | } |
| 1272 | |
| 1273 | function runLspCommand(commandFn, options = {}) { |
| 1274 | return (view) => { |
| 1275 | const resolvedView = resolveView(view); |
| 1276 | if (!resolvedView) return false; |
| 1277 | const plugin = LSPPlugin.get(resolvedView); |
| 1278 | if (!plugin) { |
| 1279 | if (!options?.silentOnMissing) { |
| 1280 | notifyLspUnavailable(); |
| 1281 | } |
| 1282 | return false; |
| 1283 | } |
| 1284 | const result = commandFn(resolvedView); |
| 1285 | return result !== false; |
| 1286 | }; |
| 1287 | } |
| 1288 | |
| 1289 | function humanizeCommandName(name) { |
| 1290 | return name |
no test coverage detected