Skip to content

Commit

Permalink
Fix location payload
Browse files Browse the repository at this point in the history
  • Loading branch information
Koray Koska committed Jul 16, 2017
1 parent eb7b65f commit deb2a45
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ public final class FacebookAttachmentPayload: JSONConvertible {
let coordinatesLat = json["coordinates"]?["lat"]?.double
let coordinatesLong = json["coordinates"]?["long"]?.double

if let url = url {
if let url = url, coordinatesLat == nil, coordinatesLong == nil {
self.init(url: url)
} else if let coordinatesLat = coordinatesLat, let coordinatesLong = coordinatesLong {
self.init(coordinatesLat: coordinatesLat, coordinatesLong: coordinatesLong)
Expand Down

0 comments on commit deb2a45

Please sign in to comment.