Closed link2xt closed 4 days ago
To test the changes in this pull request, install this apk: 📦 app-preview.apk
maybe the correct fix would be to return null in getDraft, having to ask for isOk() is harder to remember than a more visible NullPointerException
maybe the correct fix would be to return null in getDraft, having to ask for isOk() is harder to remember than a more visible NullPointerException
This is done in getProviderFromEmailWithDns
. But getMsg
does the same as getDraft
and we check for isOk
everywhere. Good thing about wrapping NULL is that if you forget to check, you will get no-op calls because FFI calls check for NULL and "ignore careless call ..." silently. This is probably better than crashing the app.
dcContext.getDraft() never returns null.