Skip to content

Commit 7bfce84

Browse files
committed
Account for token coming from WPAccount possibly being nil
1 parent fa31858 commit 7bfce84

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

WordPress/Classes/Models/WPAccount+Lookup.swift

+1-1
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ public extension WPAccount {
1818
// This is here in an extension that belongs to the apps target so we can decouple WPAccount from AppConfiguration.
1919
// Decoupling allows moving the type to WordPressData, see https://github.com/wordpress-mobile/WordPress-iOS/issues/24165.
2020
@objc
21-
static func tokenForUsername(_ username: String) -> String {
21+
static func tokenForUsername(_ username: String) -> String? {
2222
token(forUsername: username, isJetpack: AppConfiguration.isJetpack)
2323
}
2424

0 commit comments

Comments
 (0)