{"action":"created","issue":{"url":"https://api.github.com/repos/zo0r/react-native-push-notification/issues/134","repository_url":"https://api.github.com/repos/zo0r/react-native-push-notification","labels_url":"https://api.github.com/repos/zo0r/react-native-push-notification/issues/134/labels{/name}","comments_url":"https://api.github.com/repos/zo0r/react-native-push-notification/issues/134/comments","events_url":"https://api.github.com/repos/zo0r/react-native-push-notification/issues/134/events","html_url":"https://github.com/zo0r/react-native-push-notification/pull/134","id":164382208,"number":134,"title":"Upgrading to react-native 0.29","user":{"login":"clintonjrobinson","id":1816175,"avatar_url":"https://avatars.githubusercontent.com/u/1816175?v=3","gravatar_id":"","url":"https://api.github.com/users/clintonjrobinson","html_url":"https://github.com/clintonjrobinson","followers_url":"https://api.github.com/users/clintonjrobinson/followers","following_url":"https://api.github.com/users/clintonjrobinson/following{/other_user}","gists_url":"https://api.github.com/users/clintonjrobinson/gists{/gist_id}","starred_url":"https://api.github.com/users/clintonjrobinson/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/clintonjrobinson/subscriptions","organizations_url":"https://api.github.com/users/clintonjrobinson/orgs","repos_url":"https://api.github.com/users/clintonjrobinson/repos","events_url":"https://api.github.com/users/clintonjrobinson/events{/privacy}","received_events_url":"https://api.github.com/users/clintonjrobinson/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":10,"created_at":"2016-07-07T18:56:20Z","updated_at":"2016-07-12T13:15:32Z","closed_at":"2016-07-08T15:10:58Z","pull_request":{"url":"https://api.github.com/repos/zo0r/react-native-push-notification/pulls/134","html_url":"https://github.com/zo0r/react-native-push-notification/pull/134","diff_url":"https://github.com/zo0r/react-native-push-notification/pull/134.diff","patch_url":"https://github.com/zo0r/react-native-push-notification/pull/134.patch"},"body":"This is a potential upgrade to 0.29.  Since what RNPushNotification really needs in its constructor is the Application object, I just pass this in instead of the activity and use getCurrentActivity in getConstants().\r\n\r\nAnd now the MainApplication.java looks like this\r\n\r\n```\r\n\r\npublic class MainApplication extends Application implements ReactApplication {\r\n\r\n  private Application mApplication = this;\r\n\r\n  private final ReactNativeHost mReactNativeHost = new ReactNativeHost(this) {\r\n    @Override\r\n    protected boolean getUseDeveloperSupport() {\r\n      return BuildConfig.DEBUG;\r\n    }\r\n\r\n    @Override\r\n    protected List<ReactPackage> getPackages() {\r\n      return Arrays.<ReactPackage>asList(\r\n          new MainReactPackage(),\r\n          new ReactNativePushNotificationPackage(mApplication)\r\n      );\r\n    }\r\n  };\r\n\r\n  ...\r\n```"},"comment":{"url":"https://api.github.com/repos/zo0r/react-native-push-notification/issues/comments/232043402","html_url":"https://github.com/zo0r/react-native-push-notification/pull/134#issuecomment-232043402","issue_url":"https://api.github.com/repos/zo0r/react-native-push-notification/issues/134","id":232043402,"user":{"login":"kfiroo","id":284636,"avatar_url":"https://avatars.githubusercontent.com/u/284636?v=3","gravatar_id":"","url":"https://api.github.com/users/kfiroo","html_url":"https://github.com/kfiroo","followers_url":"https://api.github.com/users/kfiroo/followers","following_url":"https://api.github.com/users/kfiroo/following{/other_user}","gists_url":"https://api.github.com/users/kfiroo/gists{/gist_id}","starred_url":"https://api.github.com/users/kfiroo/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kfiroo/subscriptions","organizations_url":"https://api.github.com/users/kfiroo/orgs","repos_url":"https://api.github.com/users/kfiroo/repos","events_url":"https://api.github.com/users/kfiroo/events{/privacy}","received_events_url":"https://api.github.com/users/kfiroo/received_events","type":"User","site_admin":false},"created_at":"2016-07-12T13:15:32Z","updated_at":"2016-07-12T13:15:32Z","body":"@zo0r Thanks for the PR.\r\n\r\nI'm having a strange issue, though, when **cold starting** my app from a notification the call to `getCurrentActivity()` in `RNPushNotification.getConstants` always returns null and so the `initialNotification` constant is never available.\r\n\r\nAny ideas on how resolve / investigate this?\r\n\r\nThanks!\r\nkfir"}}
{"actor":{"display_login":"kfiroo"}}