Fixed Ruby type_of code sample