private async fireRequestAccepted()

in src/bll/weblinklistener/httphostrequest.ts [32:49]


    private async fireRequestAccepted(resourcePath: string, pars: {}): Promise<boolean> {
        const data: HttpRequestData = new HttpRequestData(resourcePath, pars);
        const workspaceFolders: any[] = this.workspaceProxy.getWorkspaceFolders();
        if (!data.isSupportedRequest() || !workspaceFolders || workspaceFolders.length === 0) {
            Logger.logInfo("HttpHostRequest#fireRequestAccepted: either request not supported either wf.len = 0");
            return false;
        }

        for (let i = 0; i < workspaceFolders.length; i++) {
            const filePath = path.join(workspaceFolders[i].uri.path, data.getFile());
            if (await this.tryShowTextDocument(filePath)) {
                Logger.logDebug(`HttpHostRequest#fireRequestAccepted: ${filePath} is opened!`);
                return true;
            }
            Logger.logDebug(`HttpHostRequest#fireRequestAccepted: attempt of opening ${filePath} has failed`);
        }
        return false;
    }