Added a before filter for generic files controller. This works with the go code, but it breaks the spec tests.