Use attr_reader for encoding, no longer env variable.