some ruby massaging
first javascript submission!