refactor(core): Move frontend settings to @n8n/api-types (no-changelog) (#10856)
This commit is contained in:
committed by
GitHub
parent
3c15890a5b
commit
430c14ad19
@@ -1,14 +1,10 @@
|
||||
import type { FrontendSettings, ITelemetrySettings } from '@n8n/api-types';
|
||||
import { GlobalConfig } from '@n8n/config';
|
||||
import { createWriteStream } from 'fs';
|
||||
import { mkdir } from 'fs/promises';
|
||||
import uniq from 'lodash/uniq';
|
||||
import { InstanceSettings } from 'n8n-core';
|
||||
import type {
|
||||
ICredentialType,
|
||||
IN8nUISettings,
|
||||
INodeTypeBaseDescription,
|
||||
ITelemetrySettings,
|
||||
} from 'n8n-workflow';
|
||||
import type { ICredentialType, INodeTypeBaseDescription } from 'n8n-workflow';
|
||||
import fs from 'node:fs';
|
||||
import path from 'path';
|
||||
import { Container, Service } from 'typedi';
|
||||
@@ -37,7 +33,7 @@ import { UrlService } from './url.service';
|
||||
|
||||
@Service()
|
||||
export class FrontendService {
|
||||
settings: IN8nUISettings;
|
||||
settings: FrontendSettings;
|
||||
|
||||
private communityPackagesService?: CommunityPackagesService;
|
||||
|
||||
@@ -247,7 +243,7 @@ export class FrontendService {
|
||||
this.writeStaticJSON('credentials', credentials);
|
||||
}
|
||||
|
||||
getSettings(pushRef?: string): IN8nUISettings {
|
||||
getSettings(pushRef?: string): FrontendSettings {
|
||||
this.eventService.emit('session-started', { pushRef });
|
||||
|
||||
const restEndpoint = this.globalConfig.endpoints.rest;
|
||||
|
||||
Reference in New Issue
Block a user