moved the ruby into a class