Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Route cannot be defined without class field #9

Open
danielevitali opened this issue Jul 9, 2015 · 0 comments
Open

Route cannot be defined without class field #9

danielevitali opened this issue Jul 9, 2015 · 0 comments

Comments

@danielevitali
Copy link

In my config json file I have declared the default route to be handled by a custom handler, without specifying the activity, in the class field.

Everytime I get a deep link which is associated with the default route, I get an a JSONException.

I think this is because you handle the route in this way

private void handleRoute(JSONObject routeOptions, Map<String, String> routeParameters) throws JSONException {
   HandlerExecutor.executeHandlers(routeOptions, routeParameters, handlers);
   IntentBuilder.buildAndFireIntent(routeOptions, routeParameters, this);
}

The handler is called correctly, but the buildAndFireIntent execute this line instruction:

String activityName = routeOptions.getString("class");

which means the route must have a class field or a JSONException will be fired.

@danielevitali danielevitali changed the title Rout cannot be defined without class field Route cannot be defined without class field Jul 9, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant