[core] move "schema" to main config.service.ts
This commit is contained in:
1 parent
13d00f954f
commit
9e098fa997
2 files changed
+3
-2
No files matched your search
@@ -7,6 +7,8 @@ import { WebhookConfig } from './structures/webhooks.config.dto';
|
||||
|
||||
@Injectable()
|
||||
export class WhatsappConfigService {
|
||||
public schema = 'http';
|
||||
|
||||
constructor(private configService: ConfigService) {}
|
||||
|
||||
get hostname(): string {
|
||||
|
||||
@@ -4,12 +4,11 @@ import { WhatsappConfigService } from '@waha/config.service';
|
||||
@Injectable()
|
||||
export class MediaLocalStorageConfig {
|
||||
public filesUri = '/api/files';
|
||||
public schema = 'http';
|
||||
|
||||
constructor(private config: WhatsappConfigService) {}
|
||||
|
||||
get filesURL(): string {
|
||||
return `${this.schema}://${this.config.hostname}:${this.config.port}${this.filesUri}/`;
|
||||
return `${this.config.schema}://${this.config.hostname}:${this.config.port}${this.filesUri}/`;
|
||||
}
|
||||
|
||||
get filesFolder(): string {
|
||||
|
||||
Reference in new issue
Block a user