Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Null pointer exception: ProfileActivity #463

Closed
wax911 opened this issue Dec 23, 2021 · 0 comments · Fixed by #465
Closed

Null pointer exception: ProfileActivity #463

wax911 opened this issue Dec 23, 2021 · 0 comments · Fixed by #465
Assignees
Labels
bug Broken functionality
Milestone

Comments

@wax911
Copy link
Member

wax911 commented Dec 23, 2021

AniTrend Issue Guidelines

Before opening a new issue, please take a moment to review our community guidelines to make the contribution process easy and effective for everyone involved.

You may find an answer in already closed issues:
https://github.com/AniTrend/anitrend-app/issues?q=is%3Aissue+is%3Aclosed

Description Of Bug

UserBase would typically not be null, especially on getName, but from what I can gather in the crashlytics logs it seems that the crash happened while the user was trying to view a hidden profile (privacy settings on anilist), so we may need to test that case scenario

Additional Context

Crashlytic Logs

com.mxt.anitrend_issue_329608f0e66d4c3bad3ec54916f36272_crash_session_61BE584601ED000110E088A54240B98B_DNE_0_v2.log

Stack Trace

Fatal Exception: java.lang.NullPointerException: Attempt to invoke virtual method 'java.lang.String com.mxt.anitrend.model.entity.base.UserBase.getName()' on a null object reference
       at com.mxt.anitrend.view.activity.detail.ProfileActivity.onOptionsItemSelected(ProfileActivity.java:126)
       at android.app.Activity.onMenuItemSelected(Activity.java:4358)
       at androidx.fragment.app.FragmentActivity.onMenuItemSelected(FragmentActivity.java:352)
       at androidx.appcompat.app.AppCompatActivity.onMenuItemSelected(AppCompatActivity.java:228)
       at androidx.appcompat.view.WindowCallbackWrapper.onMenuItemSelected(WindowCallbackWrapper.java:109)
       at androidx.appcompat.view.WindowCallbackWrapper.onMenuItemSelected(WindowCallbackWrapper.java:109)
       at androidx.appcompat.app.ToolbarActionBar$2.onMenuItemClick(ToolbarActionBar.java:65)
       at androidx.appcompat.widget.Toolbar$1.onMenuItemClick(Toolbar.java:207)
       at androidx.appcompat.widget.ActionMenuView$MenuBuilderCallback.onMenuItemSelected(ActionMenuView.java:779)
       at androidx.appcompat.view.menu.MenuBuilder.dispatchMenuItemSelected(MenuBuilder.java:834)
       at androidx.appcompat.view.menu.MenuItemImpl.invoke(MenuItemImpl.java:158)
       at androidx.appcompat.view.menu.MenuBuilder.performItemAction(MenuBuilder.java:985)
       at androidx.appcompat.view.menu.MenuBuilder.performItemAction(MenuBuilder.java:975)
       at androidx.appcompat.widget.ActionMenuView.invokeItem(ActionMenuView.java:623)
       at androidx.appcompat.view.menu.ActionMenuItemView.onClick(ActionMenuItemView.java:151)
       at android.view.View.performClick(View.java:7570)
       at android.view.View.performClickInternal(View.java:7525)
       at android.view.View.access$3900(View.java:836)
       at android.view.View$PerformClick.run(View.java:28680)
       at android.os.Handler.handleCallback(Handler.java:938)
       at android.os.Handler.dispatchMessage(Handler.java:99)
       at android.os.Looper.loop(Looper.java:263)
       at android.app.ActivityThread.main(ActivityThread.java:8276)
       at java.lang.reflect.Method.invoke(Method.java)
       at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:612)
       at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1006)
@wax911 wax911 added the bug Broken functionality label Dec 23, 2021
@wax911 wax911 added this to the 1.9.X milestone Dec 23, 2021
@wax911 wax911 linked a pull request Dec 23, 2021 that will close this issue
10 tasks
@wax911 wax911 closed this as completed in 9bfcdf2 Dec 26, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Broken functionality
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants