Skip to content

Commit

Permalink
Removed unnecessary Pathname instance creation in StubBuilder
Browse files Browse the repository at this point in the history
  • Loading branch information
shinokaro committed May 26, 2024
1 parent f310550 commit 45e94f3
Showing 1 changed file with 0 additions and 3 deletions.
3 changes: 0 additions & 3 deletions lib/ocran/stub_builder.rb
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,6 @@ def mkdir(path)

@paths[key] = path
Ocran.verbose_msg "m #{path}"
path = Ocran.Pathname(path)

write_opcode(OP_CREATE_DIRECTORY)
write_string(convert_to_native(path))
Expand All @@ -120,10 +119,8 @@ def create_file(src, tgt)
return if @files[key]

@files[key] = [tgt, src]
tgt = Ocran.Pathname(tgt)

Ocran.verbose_msg "a #{tgt}"
src = Ocran.Pathname(src)
write_opcode(OP_CREATE_FILE)
write_string(convert_to_native(tgt))
write_file(src)
Expand Down

0 comments on commit 45e94f3

Please sign in to comment.