fixed rails3 issue