Fixes Scaffold generator with --assets=false

Scaffold generator with --assets=false option 
outputs an error

See #9525
Review the CHANGELOG entry [ci skip]
Use Ruby 1.9 syntax