Skip to content

Commit

Permalink
refactor: use runContext non-deprecated methods
Browse files Browse the repository at this point in the history
  • Loading branch information
tchiotludo committed Jun 21, 2024
1 parent b52182c commit f577167
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/main/java/io/kestra/plugin/tika/Parse.java
Original file line number Diff line number Diff line change
Expand Up @@ -200,7 +200,7 @@ public Parse.Output run(RunContext runContext) throws Exception {
.build();

if (this.store) {
Path tempFile = runContext.tempFile(".ion");
Path tempFile = runContext.workingDir().createTempFile(".ion");
try (
OutputStream output = new FileOutputStream(tempFile.toFile());
) {
Expand Down Expand Up @@ -253,7 +253,7 @@ public void parseEmbedded(InputStream stream, ContentHandler handler, Metadata m
logger.debug("Extracting file {}", name);

// Upload
Path path = runContext.tempFile("." + extension);
Path path = runContext.workingDir().createTempFile("." + extension);
//noinspection ResultOfMethodCallIgnored
path.toFile().delete();

Expand Down

0 comments on commit f577167

Please sign in to comment.