mirror of
https://github.com/dadosfera/maestro.git
synced 2026-11-30 17:00:04 +00:00
Removed type and plugin from CreateNetworkConfigReq
This commit is contained in:
@@ -49,8 +49,6 @@ export class CreateNetworkConfigReq extends PickType(NetworkConfigDto, [
|
|||||||
'network_type_name',
|
'network_type_name',
|
||||||
'name',
|
'name',
|
||||||
'description',
|
'description',
|
||||||
'type',
|
|
||||||
'plugin',
|
|
||||||
]) {
|
]) {
|
||||||
@ApiProperty({ format: 'binary' })
|
@ApiProperty({ format: 'binary' })
|
||||||
ovpn_file: string;
|
ovpn_file: string;
|
||||||
|
|||||||
@@ -94,10 +94,9 @@ export class NetworkConfigService {
|
|||||||
{ customer_name, customer_id, user_id },
|
{ customer_name, customer_id, user_id },
|
||||||
): Promise<CreateNetworkConfigRes> {
|
): Promise<CreateNetworkConfigRes> {
|
||||||
const { description, name, network_type_id, network_type_name } = body;
|
const { description, name, network_type_id, network_type_name } = body;
|
||||||
let { type, plugin } = body;
|
|
||||||
|
|
||||||
type = type || 'vpn';
|
const type = 'vpn';
|
||||||
plugin = plugin || 'openvpn';
|
const plugin = 'openvpn';
|
||||||
|
|
||||||
const OVPN_FILE_STRING = Buffer.from(file.buffer).toString();
|
const OVPN_FILE_STRING = Buffer.from(file.buffer).toString();
|
||||||
|
|
||||||
|
|||||||
+1
-1
File diff suppressed because one or more lines are too long
Reference in New Issue
Block a user