airbnb / DeepLinkDispatch

A simple, annotation-based library for making deep link handling better on Android
http://nerds.airbnb.com/deeplinkdispatch/
4.39k stars 406 forks source link

Parsing a URI containing # #201

Closed tarunattri closed 7 years ago

tarunattri commented 7 years ago

I have a url like https://www.abc.foo.com/category/#/1234

Which i parse like : @DeepLink("https://{env}.foo.com/category/#/{id}")

But,

        Intent intent = getIntent();
        Bundle bundle = intent.getExtras();
        bundle.getInt("id")  

always returns invalid value.

But this works if i put the number before # as

Which i parse like : @DeepLink("https://{env}.foo.com/category/{id}/#")

Changed URL looks like I have a url like https://www.abc.foo.com/category/1234/#

Now it works. As per further search, Any variable that comes after # is not parsed be it integer or String or anything else.

Is there a workaround for this?