Added rails plugin code