Skip to content

Commit 097af33

Browse files
committed
fix logging tests
Signed-off-by: Romy <[email protected]>
1 parent 3159db9 commit 097af33

File tree

1 file changed

+7
-5
lines changed

1 file changed

+7
-5
lines changed

src/manage_nsfs/manage_nsfs_logging.js

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,14 @@
11
/* Copyright (C) 2024 NooBaa */
22
'use strict';
33

4+
const AWS = require('aws-sdk');
45
const config = require('../../config');
5-
const { throw_cli_error, write_stdout_response} = require('../manage_nsfs/manage_nsfs_cli_utils');
6+
const http_utils = require('../util/http_utils');
7+
const { CONFIG_TYPES } = require('../sdk/config_fs');
8+
const { export_logs_to_target } = require('../util/bucket_logs_utils');
69
const ManageCLIError = require('../manage_nsfs/manage_nsfs_cli_errors').ManageCLIError;
710
const ManageCLIResponse = require('../manage_nsfs/manage_nsfs_cli_responses').ManageCLIResponse;
8-
const { export_logs_to_target } = require('../util/bucket_logs_utils');
9-
const http_utils = require('../util/http_utils');
10-
const AWS = require('aws-sdk');
11+
const { throw_cli_error, write_stdout_response} = require('../manage_nsfs/manage_nsfs_cli_utils');
1112

1213
let config_fs;
1314
/** This command goes over the logs in the persistent log and move the entries to log objects in the target buckets
@@ -40,7 +41,8 @@ async function export_bucket_logging(shared_config_fs) {
4041
async function get_bucket_owner_keys(log_bucket_name) {
4142
const log_bucket_config_data = await config_fs.get_bucket_by_name(log_bucket_name);
4243
const log_bucket_owner = log_bucket_config_data.owner_account;
43-
const owner_config_data = await config_fs.get_identities_by_id(log_bucket_owner, { show_secrets: true, decrypt_secret_key: true });
44+
const owner_config_data = await config_fs.get_identity_by_id(log_bucket_owner,
45+
CONFIG_TYPES.ACCOUNT, { show_secrets: true, decrypt_secret_key: true });
4446
return owner_config_data.access_keys;
4547
}
4648

0 commit comments

Comments
 (0)