From: "Jan E." Date: 2012-07-10T22:57:22+09:00 Subject: Re: accessing hash value through variable? petter svenhard wrote in post #1068129: > '+' can't convert nil into String (TypeError) > > which is very strange since the variable does hold a md5 in string > format. the hash generates this error unless the element is called > directly with an md5 string. Then the string in the md5 variable doesn't exactly match the hash keys. Check this by inspecting the variable and comparing it to the hash keys: p md5 If you don't find the error yourself, please post the result of the expression above and an example key of the hash: p @@PATH.keys.first Maybe one of the md5 Strings is actually a byte sequence, while the other one consists of hex digits. -- Posted via http://www.ruby-forum.com/.