Skip to content

Commit

Permalink
Improve frozen error message
Browse files Browse the repository at this point in the history
  • Loading branch information
denisdefreyne committed Jul 1, 2016
1 parent 062a5ca commit 89fb5fe
Showing 1 changed file with 3 additions and 5 deletions.
8 changes: 3 additions & 5 deletions lib/nanoc/cli/error_handler.rb
Expand Up @@ -233,11 +233,9 @@ def resolution_for(error)
end
when RuntimeError
if error.message =~ /^can't modify frozen/
'You attempted to modify immutable data. Some data, such as ' \
'item/layout attributes and raw item/layout content, can not ' \
'be modified once compilation has started. (This was ' \
'unintentionally possible in 3.1.x and before, but has been ' \
'disabled in 3.2.x in order to allow compiler optimisations.)'
'You attempted to modify immutable data. Some data cannot ' \
'be modified once compilation has started. Such data includes ' \
'content and attributes of items and layouts, and filter arguments.'
end
end
end
Expand Down

0 comments on commit 89fb5fe

Please sign in to comment.