         let container = try decoder.container(keyedBy: CodingKeys.self)
         if let fileRefString: String = try container.decodeIfPresent(.fileRef) {
             fileReference = objectReferenceRepository.getOrCreate(reference: fileRefString, objects: objects)
+        }
+        if let productRefString: String = try container.decodeIfPresent(.productRef) {
+            productReference = objectReferenceRepository.getOrCreate(reference: productRefString, objects: objects)
         }
         settings = try container.decodeIfPresent([String: Any].self, forKey: .settings)
         try super.init(from: decoder)

    }
    
    /// Product reference.
    public var productReference: PBXObjectReference?

    /// Element settings
    public var settings: [String: Any]?

    enum CodingKeys: String, CodingKey {
        case fileRef
        case settings
        case productRef
    }

    public required init(from decoder: Decoder) throws {
