Skip to content

Commit

Permalink
Fix thread bug when presenting errors
Browse files Browse the repository at this point in the history
  • Loading branch information
goranmoomin committed Mar 6, 2022
1 parent 596c970 commit dd1a0a4
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
3 changes: 2 additions & 1 deletion HackerNews/AppDelegate.swift
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,8 @@ import HNAPI
result in
switch result {
case .success(let token): Token.current = token
case .failure(let error): NSApplication.shared.presentError(error)
case .failure(let error):
DispatchQueue.main.async { NSApplication.shared.presentError(error) }
}
}
}
Expand Down
2 changes: 1 addition & 1 deletion HackerNews/Info.plist
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
<key>CFBundleShortVersionString</key>
<string>0.1.0</string>
<key>CFBundleVersion</key>
<string>75</string>
<string>80</string>
<key>LSMinimumSystemVersion</key>
<string>$(MACOSX_DEPLOYMENT_TARGET)</string>
<key>NSMainStoryboardFile</key>
Expand Down

0 comments on commit dd1a0a4

Please sign in to comment.