akmittal006 / PingMe

whatsapp like android app
3 stars 2 forks source link

NullPointerException when running Ping Me #4

Open Pmagz opened 8 years ago

Pmagz commented 8 years ago

Hi Ankur, Love this app. I have been trying to build the app but get this error. Checked again and again, got nowhere. Please help.

12-30 13:16:11.867: E/AndroidRuntime(2006): FATAL EXCEPTION: main 12-30 13:16:11.867: E/AndroidRuntime(2006): Process: com.ankurmittal.learning, PID: 2006 12-30 13:16:11.867: E/AndroidRuntime(2006): java.lang.RuntimeException: Unable to start activity ComponentInfo{com.ankurmittal.learning/com.ankurmittal.learning.ChatListActivity}: java.lang.NullPointerException 12-30 13:16:11.867: E/AndroidRuntime(2006): at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2184) 12-30 13:16:11.867: E/AndroidRuntime(2006): at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2233) 12-30 13:16:11.867: E/AndroidRuntime(2006): at android.app.ActivityThread.access$800(ActivityThread.java:135) 12-30 13:16:11.867: E/AndroidRuntime(2006): at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1196) 12-30 13:16:11.867: E/AndroidRuntime(2006): at android.os.Handler.dispatchMessage(Handler.java:102) 12-30 13:16:11.867: E/AndroidRuntime(2006): at android.os.Looper.loop(Looper.java:136) 12-30 13:16:11.867: E/AndroidRuntime(2006): at android.app.ActivityThread.main(ActivityThread.java:5001) 12-30 13:16:11.867: E/AndroidRuntime(2006): at java.lang.reflect.Method.invokeNative(Native Method) 12-30 13:16:11.867: E/AndroidRuntime(2006): at java.lang.reflect.Method.invoke(Method.java:515) 12-30 13:16:11.867: E/AndroidRuntime(2006): at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:785) 12-30 13:16:11.867: E/AndroidRuntime(2006): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:601) 12-30 13:16:11.867: E/AndroidRuntime(2006): at dalvik.system.NativeStart.main(Native Method) 12-30 13:16:11.867: E/AndroidRuntime(2006): Caused by: java.lang.NullPointerException 12-30 13:16:11.867: E/AndroidRuntime(2006): at com.ankurmittal.learning.ChatListActivity.onCreate(ChatListActivity.java:124)

Kind Regards, P

akmittal006 commented 8 years ago

are you using your own parse keys?

Pmagz commented 8 years ago

yes i am. But even with yours still has the same issue

akmittal006 commented 8 years ago

you can never use your parse keys unless u replicate my cloud functions or their functionality. If you are using mine , which commit are you trying to run?

Pmagz commented 8 years ago

i am using your latest commit 8ef7a59 chngeDb one

akmittal006 commented 8 years ago

I checked out line 124 , it is empty. have you made changes? if so then plz post the line. it may be because current parse user is null. use if condition to redirect it to login page.