rdrop / exponent-server-sdk-elixir

Use to send push notifications to Exponent Experiences from an Elixir/Phoenix server.
MIT License
19 stars 15 forks source link

Modify the typespec for functions push and push_list #3

Open ston88 opened 4 years ago

ston88 commented 4 years ago

Thanks for making this repo!

My dialyzer showed error "breaks the contract" when passing a map or list(map) as the argument for functions PushNotification.push/1 and PushNotification.push_list/1 respectively.

I found out that those functions were expecting the type PushMessage.t() instead of map.

Please let me know what do you guys think!

Kind Regards

fmarkwong commented 4 years ago

I'm running into this issue too and have to dialyzer ignore the line. @ston88 solution looks good. cc: @rdrop

rdrop commented 4 years ago

I'll look into this and confirm next week, thanks for the PR

mrmurphy commented 3 years ago

Me too, I ended up dropping this attribute above my function to quiet the error:

@dialyzer {:no_return, g: 0}
hogiyogi597 commented 1 year ago

Ran into this as well. Would love to get this accepted into the library. Is this still maintained?