<html><head><meta http-equiv="Content-Type" content="text/html charset=windows-1252"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;"><div>Hi,</div><div><br></div><div>Currently the plugin supports only one set of varaintId and secret and if you want to create an application for android and iOS you would have logic like</div><div><pre style="box-sizing: border-box; margin-top: 15px; margin-bottom: 15px; background-color: rgb(248, 248, 248); border: 1px solid rgb(221, 221, 221); overflow: auto; padding: 6px 10px; border-top-left-radius: 3px; border-top-right-radius: 3px; border-bottom-right-radius: 3px; border-bottom-left-radius: 3px; word-wrap: normal;"><div style="color: rgb(0, 0, 0); font-size: 12px; line-height: normal; white-space: normal;"><font face="Courier">if (device.platform == ‘android’) {</font></div><div style="color: rgb(0, 0, 0); font-size: 12px; line-height: normal; white-space: normal;"><font face="Courier">&nbsp; &nbsp;variantId =&nbsp;</font><span style="color: rgb(221, 17, 68); font-family: Consolas, 'Liberation Mono', Courier, monospace; line-height: 16px; white-space: pre; background-color: rgb(255, 255, 255);">"&lt;variantID for android&gt;"</span><font face="Courier">;</font></div><div style="color: rgb(0, 0, 0); font-size: 12px; line-height: normal; white-space: normal;"><font face="Courier">} else {</font></div><div><font face="Courier" style="color: rgb(0, 0, 0); font-size: 12px; line-height: normal; white-space: normal;">&nbsp; &nbsp;variantId =&nbsp;</font><span style="background-color: rgb(255, 255, 255);"><font color="#dd1144" face="Consolas, Liberation Mono, Courier, monospace"><span style="line-height: 16px;">"&lt;variantID for iOS&gt;"</span></font></span><font face="Courier" style="color: rgb(0, 0, 0); font-size: 12px; line-height: normal; white-space: normal;">;</font></div><div style="color: rgb(0, 0, 0); font-size: 12px; line-height: normal; white-space: normal;"><font face="Courier">}</font></div></pre></div><div>so with this grouping you don’t have to have this if else logic anymore as you can just add them in the config like so:</div><div><pre style="box-sizing: border-box; font-family: Consolas, 'Liberation Mono', Courier, monospace; font-size: 13px; margin-top: 15px; margin-bottom: 15px; background-color: rgb(248, 248, 248); border: 1px solid rgb(221, 221, 221); line-height: 19px; overflow: auto; padding: 6px 10px; border-top-left-radius: 3px; border-top-right-radius: 3px; border-bottom-right-radius: 3px; border-bottom-left-radius: 3px; word-wrap: normal; color: rgb(51, 51, 51);"><pre style="color: rgb(0, 0, 0); font-size: 12px; font-family: Consolas, 'Liberation Mono', Courier, monospace; line-height: 16.799999237060547px; width: 744px; margin-top: 0px; margin-bottom: 0px; padding: 0px; background-color: rgb(255, 255, 255); position: static; z-index: auto;"><div><div><span style="color: rgb(51, 51, 51); font-size: 13px; line-height: 19px; font-weight: bold;">var</span><span style="background-color: rgb(248, 248, 248); color: rgb(51, 51, 51); font-size: 13px; line-height: 19px;"> </span><span style="color: rgb(51, 51, 51); font-size: 13px; line-height: 19px;">pushConfig</span><span style="background-color: rgb(248, 248, 248); color: rgb(51, 51, 51); font-size: 13px; line-height: 19px;"> </span><span style="color: rgb(51, 51, 51); font-size: 13px; line-height: 19px; font-weight: bold;">= </span><span style="line-height: 16.799999237060547px;">{</span></div>
<div class="">    pushServerURL<span style="font-weight: bold;">:</span> <span style="color: rgb(221, 17, 68);">"&lt;pushServerURL e.g http(s)//host:port/context &gt;"</span>,</div></div><div class=""><div>
    alias<span style="font-weight: bold;">:</span> <span style="color: rgb(221, 17, 68);">"&lt;alias e.g. a username or an email address optional&gt;"</span>,</div><div>    android<span style="font-weight: bold;">:</span> {</div>
<div>      senderID<span style="font-weight: bold;">:</span> <span style="color: rgb(221, 17, 68);">"&lt;senderID e.g Google Project ID only for android&gt;"</span>,</div><div><div>      variantID<span style="font-weight: bold;">:</span> <span style="color: rgb(221, 17, 68);">"&lt;variantID e.g. 1234456-234320&gt;"</span>,</div>
<div>      variantSecret<span style="font-weight: bold;">:</span> <span style="color: rgb(221, 17, 68);">"&lt;variantSecret e.g. 1234456-234320&gt;"</span></div></div><div>    },</div></div><div class=""><div>    ios<span style="font-weight: bold;">:</span> {</div>
<div><div>      variantID<span style="font-weight: bold;">:</span> <span style="color: rgb(221, 17, 68);">"&lt;variantID e.g. 1234456-234320&gt;"</span>,</div><div>      variantSecret<span style="font-weight: bold;">:</span> <span style="color: rgb(221, 17, 68);">"&lt;variantSecret e.g. 1234456-234320&gt;"</span></div>
<div>    }</div></div></div><div>};</div></pre></pre></div><div>And when a windows phone is added you’ll still have to change the code to add the variantId for windows. As we don’t have a way to register for the application only for the variant this is the compromise.</div><div><span class="p" style="box-sizing: border-box;"><br></span></div><div><span class="p" style="box-sizing: border-box;">Cheers,</span></div><div><span class="p" style="box-sizing: border-box;"><span class="Apple-tab-span" style="white-space:pre">        </span>Erik Jan</span></div><br></body></html>