Fix rednering BadRequest

Using temporary solution till
http://projects.theforeman.org/issues/3957 gets fixed.