adding some edge cases to resource deserialization