Skip to content

Commit

Permalink
local variable renamed
Browse files Browse the repository at this point in the history
  • Loading branch information
OluchukwuCatherineObi-Njoku committed Oct 31, 2023
1 parent 6057ee8 commit 2f74e5f
Showing 1 changed file with 6 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -70,22 +70,22 @@ public class FileAuditEndpoint implements AuditEndpoint {
}

void setFile(final File file) throws IOException {
boolean isSetUp = false;
boolean isFileSet = false;
final FileOutputStream fos = new FileOutputStream(file, true);
try {
final Writer writer = new OutputStreamWriter(new BufferedOutputStream(fos), this.charset);
try {
this.fileDescriptor = fos.getFD();
this.writer = writer;
this.file = file;
isSetUp = true;
isFileSet = true;
} finally {
if (! isSetUp) {
if (! isFileSet) {
safeClose(writer);
}
}
} finally {
if (! isSetUp) {
if (! isFileSet) {
safeClose(fos);
}
}
Expand All @@ -108,7 +108,7 @@ private void safeClose(Closeable c) {
* This method can be overridden by subclasses to modify data written into file (to encrypt them for example),
* or just for counting amount of written bytes for needs of log rotation and similar.
*
* This method can be invisSetUped only in synchronization block surrounding one log message processing.
* This method can be invoked only in synchronization block surrounding one log message processing.
*
* @param toWrite the String to be written into the target local file
*/
Expand All @@ -121,7 +121,7 @@ void write(String toWrite) throws IOException {
* This method is NO-OP by default. It is intended to be overridden by subclasses
* which need to perform some operation before every writing into the target local file.
*
* This method can be invisSetUped only in synchronization block surrounding one log message processing.
* This method can be invisFileSeted only in synchronization block surrounding one log message processing.
*
* @param instant time of the message acceptance
*/
Expand Down

0 comments on commit 2f74e5f

Please sign in to comment.