Skip to content

Commit 53d5cd9

Browse files
committed
remove unused parameter in decryption failed event
1 parent 311b86c commit 53d5cd9

File tree

3 files changed

+3
-4
lines changed

3 files changed

+3
-4
lines changed

src/main/java/org/cryptomator/cryptofs/event/DecryptionFailedEvent.java

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,10 +7,9 @@
77
/**
88
* Emitted, if a decryption operation fails.
99
*
10-
* @param cleartextPath path within the cryptographic filesystem
1110
* @param ciphertextPath path to the encrypted resource
1211
* @param e thrown exception
1312
*/
14-
public record DecryptionFailedEvent(Path cleartextPath, Path ciphertextPath, AuthenticationFailedException e) implements FilesystemEvent {
13+
public record DecryptionFailedEvent(Path ciphertextPath, AuthenticationFailedException e) implements FilesystemEvent {
1514

1615
}

src/main/java/org/cryptomator/cryptofs/fh/ChunkLoader.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@ public ByteBuffer load(Long chunkIndex) throws IOException, AuthenticationFailed
5353
}
5454
return cleartextBuf;
5555
} catch (AuthenticationFailedException e) {
56-
eventConsumer.accept(new DecryptionFailedEvent(null, path.get(), e));
56+
eventConsumer.accept(new DecryptionFailedEvent(path.get(), e));
5757
throw e;
5858
} finally {
5959
bufferPool.recycle(ciphertextBuf);

src/main/java/org/cryptomator/cryptofs/fh/FileHeaderHolder.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -82,7 +82,7 @@ FileHeader loadExisting(FileChannel ch) throws IOException {
8282
return existingHeader;
8383
} catch (IllegalArgumentException | CryptoException e) {
8484
if (e instanceof AuthenticationFailedException afe) {
85-
eventConsumer.accept(new DecryptionFailedEvent(null, path.get(), afe));
85+
eventConsumer.accept(new DecryptionFailedEvent(path.get(), afe));
8686
}
8787
throw new IOException("Unable to decrypt header of file " + path.get(), e);
8888
}

0 commit comments

Comments
 (0)