mirror of
https://github.com/caoer/CodableFirebase.git
synced 2026-06-12 16:08:02 +08:00
Compare commits
3 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
3cae6e90d9 | ||
|
|
222b080693 | ||
|
|
5b8627dbbe |
@@ -1,6 +1,6 @@
|
|||||||
Pod::Spec.new do |s|
|
Pod::Spec.new do |s|
|
||||||
s.name = "CodableFirebase"
|
s.name = "CodableFirebase"
|
||||||
s.version = "0.0.6"
|
s.version = "0.0.7"
|
||||||
s.summary = "Use Codable with Firebase"
|
s.summary = "Use Codable with Firebase"
|
||||||
s.description = "This library helps you use your custom models that conform to Codable protocol with Firebase Realtime Database and Firestore"
|
s.description = "This library helps you use your custom models that conform to Codable protocol with Firebase Realtime Database and Firestore"
|
||||||
s.homepage = "https://github.com/alickbass/CodableFirebase"
|
s.homepage = "https://github.com/alickbass/CodableFirebase"
|
||||||
|
|||||||
@@ -393,11 +393,20 @@ extension _FirebaseEncoder {
|
|||||||
}
|
}
|
||||||
|
|
||||||
// The value should request a container from the _FirebaseEncoder.
|
// The value should request a container from the _FirebaseEncoder.
|
||||||
let depth = storage.count
|
let depth = self.storage.count
|
||||||
try value.encode(to: self)
|
do {
|
||||||
|
try value.encode(to: self)
|
||||||
|
} catch {
|
||||||
|
// If the value pushed a container before throwing, pop it back off to restore state.
|
||||||
|
if self.storage.count > depth {
|
||||||
|
let _ = self.storage.popContainer()
|
||||||
|
}
|
||||||
|
|
||||||
|
throw error
|
||||||
|
}
|
||||||
|
|
||||||
// The top container should be a new container.
|
// The top container should be a new container.
|
||||||
guard storage.count > depth else {
|
guard self.storage.count > depth else {
|
||||||
return nil
|
return nil
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -15,7 +15,7 @@
|
|||||||
<key>CFBundlePackageType</key>
|
<key>CFBundlePackageType</key>
|
||||||
<string>FMWK</string>
|
<string>FMWK</string>
|
||||||
<key>CFBundleShortVersionString</key>
|
<key>CFBundleShortVersionString</key>
|
||||||
<string>0.0.6</string>
|
<string>0.0.7</string>
|
||||||
<key>CFBundleVersion</key>
|
<key>CFBundleVersion</key>
|
||||||
<string>$(CURRENT_PROJECT_VERSION)</string>
|
<string>$(CURRENT_PROJECT_VERSION)</string>
|
||||||
<key>NSPrincipalClass</key>
|
<key>NSPrincipalClass</key>
|
||||||
|
|||||||
Reference in New Issue
Block a user