fix bug with rails gun