Fix bug with asset pipeline.

Check path filters before appending button content to request body.

`@env` assign is moved to top (otherwise all default options will not be merged to `env`).
`self.options` assign is moved to top (otherwise no rack-inside options will be found inside `env`).