You should define a default value in case type key doesn't exist (or throw exception)