From 1a140c93e9c04b7507d470621e953ddc2a99520b Mon Sep 17 00:00:00 2001 From: Sam Wilkins Date: Thu, 11 Jul 2019 02:35:15 -0400 Subject: removed extraneous docs namespace --- src/client/documents/Documents.ts | 16 +--------------- 1 file changed, 1 insertion(+), 15 deletions(-) (limited to 'src') diff --git a/src/client/documents/Documents.ts b/src/client/documents/Documents.ts index 5a3f9574f..961cd3479 100644 --- a/src/client/documents/Documents.ts +++ b/src/client/documents/Documents.ts @@ -57,20 +57,6 @@ export enum DocumentType { LINK = "link" } -export namespace DocTypeUtils { - - export function values(includeNone: boolean = true): string[] { - let types = Object.values(DocumentType); - return includeNone ? types : types.filter(key => key !== DocumentType.NONE); - } - - export function keys(includeNone: boolean = true): string[] { - let types = Object.keys(DocumentType); - return includeNone ? types : types.filter(key => key !== DocumentType.NONE); - } - -} - export interface DocumentOptions { x?: number; y?: number; @@ -174,7 +160,7 @@ export namespace Docs { export async function initialize(): Promise { // non-guid string ids for each document prototype let suffix = "Proto"; - let prototypeIds: string[] = DocTypeUtils.values(false).map(type => type + suffix); + let prototypeIds = Object.values(DocumentType).filter(type => type !== DocumentType.NONE).map(type => type + suffix); // fetch the actual prototype documents from the server let actualProtos = await DocServer.GetRefFields(prototypeIds); -- cgit v1.2.3-70-g09d2