Use guard clauses.
This commit is contained in:
parent
9f513cc60c
commit
ceec5a82c1
@ -11,10 +11,9 @@ module Hbc
|
|||||||
@token = token
|
@token = token
|
||||||
@sourcefile_path = sourcefile_path
|
@sourcefile_path = sourcefile_path
|
||||||
@dsl = dsl || DSL.new(@token)
|
@dsl = dsl || DSL.new(@token)
|
||||||
if block_given?
|
return unless block_given?
|
||||||
@dsl.instance_eval(&block)
|
@dsl.instance_eval(&block)
|
||||||
@dsl.language_eval
|
@dsl.language_eval
|
||||||
end
|
|
||||||
end
|
end
|
||||||
|
|
||||||
DSL::DSL_METHODS.each do |method_name|
|
DSL::DSL_METHODS.each do |method_name|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user