Fix block handling in link_to helper

The current link_to implementation fails with the block syntax due to the way Rails [renames the attributes](https://github.com/rails/rails/blob/4-1-stable/actionview/lib/action_view/helpers/url_helper.rb#L176) in this scenario.

This PR just cherry-picks a fix from Yarbro's fork: https://github.com/yarbro/meta_events