Device being stored by SmartApp as a string


(Eric R) #1

In my Pushbullet Notifier app, I’ve had a couple users bring up a problem they have had recently. Currently, I’m working with @eibyer on this. I have not been able to produce this myself, but it is happening to more than one person. I have this input:

input "pushbullets", "device.pushbullet", title: "Pushbullet Device(s)", multiple: true, required: true

Then when push() is called, it says it can’t be called on a string. Then when I log what it is trying to call push() on, it is the device’s id hash string. Any idea why this may be happening?


(Tim Slagle) #2

No idea…

Similar code in another app works fine… Your app does not for me… Super weird lol


(Eric R) #3

Are you using android or iOS?


(Tim Slagle) #4

Both :\



(Eric R) #5

Does the app not work on both devices?


(Tim Slagle) #6

You got it :smile:

I tried debugging it on my own but gave up lol


(Alex) #7

I had the exact same problem with SmartTiles on Android 1.7+ when you ask for particular device as input on a dynamic page.

No resolution from SM for over a month.

To overcome this, try to rearrange your input so that it would appear on a static page.


(Eric R) #8

I never thought of mixing static and dynamic pages. It’s probably better to make pages static unless absolutely necessary. I’ve edited my code. I haven’t updated github yet. Hopefully will do that later today.


(Eric R) #9

Now updated on github.