make it a bit less phpee and a bit more rubyee