Fix emoji interaction json parsing

This commit is contained in:
Ilya Laktyushin 2021-09-13 18:42:35 +03:00
parent 4d10406d3e
commit f16431d83f

View File

@ -32,7 +32,7 @@ public struct EmojiInteraction: Equatable {
var animations: [EmojiInteraction.Animation] = []
for animationDict in animationsArray {
if let animationDict = animationDict as? [String: Any] {
if let index = animationDict["i"] as? Int, let timeOffset = animationDict["t"] as? Float {
if let index = animationDict["i"] as? Int, let timeOffset = animationDict["t"] as? Double {
animations.append(EmojiInteraction.Animation(index: index, timeOffset: timeOffset))
}
}