Skip to content

Commit

Permalink
Just use the config directly.
Browse files Browse the repository at this point in the history
  • Loading branch information
danfuzz committed Apr 5, 2023
1 parent ad40b0d commit f782993
Showing 1 changed file with 2 additions and 6 deletions.
8 changes: 2 additions & 6 deletions src/builtin-services/export/RequestLogger.js
Original file line number Diff line number Diff line change
Expand Up @@ -22,9 +22,6 @@ import { IntfRequestLogger } from '@this/network-protocol';
* @implements {IntfRequestLogger}
*/
export class RequestLogger extends BaseService {
/** @type {string} Full path to the log file. */
#logFilePath;

/** @type {?Rotator} File rotator to use, if any. */
#rotator;

Expand All @@ -37,13 +34,12 @@ export class RequestLogger extends BaseService {
constructor(config, logger) {
super(config, logger);

this.#logFilePath = config.path;
this.#rotator = config.rotate ? new Rotator(config, this.logger) : null;
this.#rotator = config.rotate ? new Rotator(config, this.logger) : null;
}

/** @override */
async logCompletedRequest(line) {
await fs.appendFile(this.#logFilePath, `${line}\n`);
await fs.appendFile(this.config.path, `${line}\n`);
}

/** @override */
Expand Down

0 comments on commit f782993

Please sign in to comment.