this check for nil everywhere makes me crazy. in ruby you usually use reader, that ensure that it is e.g. always hash, so you get `{}` if not initialized or do lazy initialization.