Compare commits

...

3 Commits

3 changed files with 3 additions and 7 deletions

View File

@ -30,11 +30,7 @@ public class Notification: Decodable {
} }
self.createdAt = try container.decode(Date.self, forKey: .createdAt) self.createdAt = try container.decode(Date.self, forKey: .createdAt)
self.account = try container.decode(Account.self, forKey: .account) self.account = try container.decode(Account.self, forKey: .account)
if container.contains(.status) { self.status = try container.decodeIfPresent(Status.self, forKey: .status)
self.status = try container.decode(Status.self, forKey: .status)
} else {
self.status = nil
}
} }
public static func dismiss(id notificationID: String) -> Request<Empty> { public static func dismiss(id notificationID: String) -> Request<Empty> {

View File

@ -112,7 +112,7 @@ class ProfileDirectoryViewController: UIViewController {
private func updateProfiles() { private func updateProfiles() {
let scope = self.scope let scope = self.scope
let order = self.order let order = self.order
let local = scope == .everywhere let local = scope == .instance
let request = Client.getFeaturedProfiles(local: local, order: order) let request = Client.getFeaturedProfiles(local: local, order: order)
mastodonController.run(request) { (response) in mastodonController.run(request) { (response) in
guard case let .success(accounts, _) = response, guard case let .success(accounts, _) = response,

View File

@ -18,7 +18,7 @@ class ProfileFieldsView: UIView {
private var isUsingSingleColumn: Bool = false private var isUsingSingleColumn: Bool = false
private var needsSingleColumn: Bool { private var needsSingleColumn: Bool {
traitCollection.preferredContentSizeCategory > .large traitCollection.horizontalSizeClass == .compact && traitCollection.preferredContentSizeCategory > .extraLarge
} }
override init(frame: CGRect) { override init(frame: CGRect) {