Ruby and Rails string extensions