Skip to content

Commit ff11e38

Browse files
committed
Merge remote-tracking branch 'origin/main' into develop
2 parents daa4919 + 04eaa96 commit ff11e38

File tree

3 files changed

+6
-11
lines changed

3 files changed

+6
-11
lines changed

CHANGELOG.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,11 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
77

88
## [Unreleased]
99

10+
## [0.3.3] - 2022-02-17
11+
12+
### Changed
13+
- `engine/function`: remove object finalizer (fixes [#14](https://github.com/gi/handlebars-ruby/issues/14))
14+
1015
## [0.3.2] - 2022-02-17
1116

1217
### Changed

lib/handlebars/engine/function.rb

Lines changed: 0 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -7,21 +7,11 @@ class Function
77
def initialize(context, name)
88
@context = context
99
@name = name
10-
ObjectSpace.define_finalizer(self, self.class.finalizer(context, name))
1110
end
1211

1312
def call(*args)
1413
@context.call(@name, *args)
1514
end
16-
17-
def self.finalizer(context, name)
18-
proc {
19-
begin
20-
context.eval("delete #{name}")
21-
rescue ThreadError # rubocop:disable Lint/SuppressedException
22-
end
23-
}
24-
end
2515
end
2616
end
2717
end

lib/handlebars/engine/version.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,6 @@
22

33
module Handlebars
44
class Engine
5-
VERSION = "0.3.2"
5+
VERSION = "0.3.3"
66
end
77
end

0 commit comments

Comments
 (0)