mirror of
https://github.com/microsoft/vscode.git
synced 2026-05-08 09:08:48 +01:00
@@ -131,7 +131,10 @@ export function log(entry: IRemoteConsoleLog, label: string): void {
|
||||
}
|
||||
|
||||
// Log it
|
||||
console[entry.severity].apply(console, consoleArgs);
|
||||
if (typeof (console as any)[entry.severity] !== 'function') {
|
||||
throw new Error('Unknown console method');
|
||||
}
|
||||
(console as any)[entry.severity].apply(console, consoleArgs);
|
||||
}
|
||||
|
||||
function color(color: string): string {
|
||||
|
||||
@@ -237,7 +237,7 @@ export class SQLiteStorageDatabase implements IStorageDatabase {
|
||||
const connection = await this.whenConnected;
|
||||
const row = await this.get(connection, full ? 'PRAGMA integrity_check' : 'PRAGMA quick_check');
|
||||
|
||||
const integrity = full ? row['integrity_check'] : row['quick_check'];
|
||||
const integrity = full ? (row as any)['integrity_check'] : (row as any)['quick_check'];
|
||||
|
||||
if (connection.isErroneous) {
|
||||
return `${integrity} (last error: ${connection.lastError})`;
|
||||
|
||||
@@ -29,8 +29,8 @@ export class Query {
|
||||
if (hasSort && command === 'sort' || hasCategory && command === 'category') {
|
||||
return [];
|
||||
}
|
||||
if (subcommands[command]) {
|
||||
return subcommands[command].map((subcommand: string) => `@${command}:${subcommand}${subcommand === '' ? '' : ' '}`);
|
||||
if ((subcommands as any)[command]) {
|
||||
return (subcommands as any)[command].map((subcommand: string) => `@${command}:${subcommand}${subcommand === '' ? '' : ' '}`);
|
||||
}
|
||||
else {
|
||||
return [`@${command} `];
|
||||
|
||||
@@ -21,6 +21,7 @@ import { IContextKeyService } from 'vs/platform/contextkey/common/contextkey';
|
||||
import { ViewletDescriptor } from 'vs/workbench/browser/viewlet';
|
||||
import { Registry } from 'vs/platform/registry/common/platform';
|
||||
import { CancellationToken } from 'vs/base/common/cancellation';
|
||||
import { IStringDictionary } from 'vs/base/common/collections';
|
||||
|
||||
export const VIEW_PICKER_PREFIX = 'view ';
|
||||
|
||||
@@ -101,7 +102,7 @@ export class ViewPickerHandler extends QuickOpenHandler {
|
||||
return true;
|
||||
});
|
||||
|
||||
const entryToCategory = {};
|
||||
const entryToCategory: IStringDictionary<string> = {};
|
||||
entries.forEach(e => {
|
||||
if (!entryToCategory[e.getLabel()]) {
|
||||
entryToCategory[e.getLabel()] = e.getCategory();
|
||||
|
||||
Reference in New Issue
Block a user