diff --git a/CHANGELOG.md b/CHANGELOG.md index b361805..70c2c3e 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,7 @@ +## [0.1.9] - 2024-06-03 + +- Fix the signature of `new` class method + ## [0.1.8] - 2024-05-15 - Sort attribute names in the tapioca compiler diff --git a/Gemfile.lock b/Gemfile.lock index 0831a2b..9464d1a 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -1,7 +1,7 @@ PATH remote: . specs: - shale-builder (0.1.8) + shale-builder (0.1.9) booleans (>= 0.1) shale (< 2.0) sorbet-runtime (> 0.5) diff --git a/lib/shale/builder.rb b/lib/shale/builder.rb index 418c86a..0ab0dcc 100644 --- a/lib/shale/builder.rb +++ b/lib/shale/builder.rb @@ -88,8 +88,8 @@ def build(&_block) body end - sig { abstract.returns(T.attached_class) } - def new; end + sig { abstract.params(props: T.anything).returns(T.attached_class) } + def new(**props); end sig { abstract.returns(T::Hash[Symbol, Shale::Attribute]) } def attributes; end diff --git a/lib/shale/builder/version.rb b/lib/shale/builder/version.rb index 775a049..0fa6773 100644 --- a/lib/shale/builder/version.rb +++ b/lib/shale/builder/version.rb @@ -2,6 +2,6 @@ module Shale module Builder - VERSION = '0.1.8' + VERSION = '0.1.9' end end