trying to fix issue when interacting with your_platform.

On some occasions, this error has been raised:
  NoMethodError: undefined method `reverse' for nil:NilClass.

This issue might be related:
  https://github.com/rails/rails/issues/7538

The dirty hack with 'begin ... rescue ... end' fixes the issue.