added support for rails