{"id":5953,"date":"2019-01-14T16:44:06","date_gmt":"2019-01-14T14:44:06","guid":{"rendered":"http:\/\/mummila.net\/kommentit\/?p=5953"},"modified":"2019-01-14T16:44:06","modified_gmt":"2019-01-14T14:44:06","slug":"make-sure-that-the-value-of-gcmsenderid-still-has-the-trailing-backslash","status":"publish","type":"post","link":"https:\/\/mummila.net\/kommentit\/2019\/01\/14\/make-sure-that-the-value-of-gcmsenderid-still-has-the-trailing-backslash\/","title":{"rendered":"Make sure that the value of gcmSenderId still has the trailing backslash"},"content":{"rendered":"<p>A hint for anyone googling for this: make sure that the value of\u00a0<code>gcmSenderId<\/code>\u00a0in your <code>AndroidManifest.xml<\/code>still has\u00a0<a href=\"https:\/\/github.com\/mattermost\/mattermost-mobile\/blob\/0af947476e31d8dac26950807c3cf49d93443a16\/android\/app\/src\/main\/AndroidManifest.xml#L24\">the trailing backslash (\\)<\/a>\u00a0after you&#8217;ve changed the project number to your own.\u00a0<a href=\"https:\/\/stackoverflow.com\/questions\/2154945\/how-to-force-a-meta-data-value-to-type-string\/2155358\" rel=\"nofollow\">Otherwise the value gets interpreted as int, when it should be a string<\/a>, which is one way to trigger the issue of devices being assigned empty\/null IDs.<\/p>\n<p>(<a href=\"https:\/\/developers.mattermost.com\/contribute\/mobile\/build-your-own\/#set-up-android-to-receive-push-notifications\" rel=\"nofollow\">The building instructions do have this documented in bold<\/a>, but it&#8217;s still very easy to miss, I know I did. Complicating the debugging was my Nexus 5X, which kept getting a proper device ID even when all other devices using the same broken build failed to.)<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Otherwise the value gets interpreted as int, when it should be a string, which is one way to trigger the issue of devices being assigned empty IDs.<\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[8860],"tags":[12572,589,14049,12589],"class_list":["post-5953","post","type-post","status-publish","format-standard","hentry","category-vianhallintajarjestelmat","tag-android","tag-google","tag-mattermost","tag-nexus","sijainti-github"],"_links":{"self":[{"href":"https:\/\/mummila.net\/kommentit\/wp-json\/wp\/v2\/posts\/5953","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/mummila.net\/kommentit\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/mummila.net\/kommentit\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/mummila.net\/kommentit\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/mummila.net\/kommentit\/wp-json\/wp\/v2\/comments?post=5953"}],"version-history":[{"count":2,"href":"https:\/\/mummila.net\/kommentit\/wp-json\/wp\/v2\/posts\/5953\/revisions"}],"predecessor-version":[{"id":5955,"href":"https:\/\/mummila.net\/kommentit\/wp-json\/wp\/v2\/posts\/5953\/revisions\/5955"}],"wp:attachment":[{"href":"https:\/\/mummila.net\/kommentit\/wp-json\/wp\/v2\/media?parent=5953"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/mummila.net\/kommentit\/wp-json\/wp\/v2\/categories?post=5953"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/mummila.net\/kommentit\/wp-json\/wp\/v2\/tags?post=5953"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}