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

Open Linker for extension #730

Merged
merged 4 commits into from
Aug 11, 2014
Merged

Open Linker for extension #730

merged 4 commits into from
Aug 11, 2014

Conversation

dtelaroli
Copy link
Contributor

In addition to the #702 as dependency on the caelum/vraptor-i18n#32

@@ -44,6 +45,23 @@ public Linker(ServletContext context, Router router, Class<?> controller, String
}

protected String getLink() {
Method method = getMethod();
return getContextPath() + router.urlFor(controller, method, getArgs(method));
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

change controller to getController()

@dtelaroli
Copy link
Contributor Author

@lucascs it was used by the I18nLinker, but I changed to return the router.

@Turini Turini added duplicate and removed duplicate labels Aug 5, 2014
@lucascs
Copy link
Member

lucascs commented Aug 5, 2014

@dtelaroli if we pass the router on the constructor manually, we don't need to have this getRouter

@dtelaroli
Copy link
Contributor Author

@lucascs the your comment was pointed on the constructor code, I thought that you have mentioned the properties, so, I will remove the getController too.

@lucascs
Copy link
Member

lucascs commented Aug 5, 2014

it was indeed to remove unnecessary getters =)

return getContextPath() + router.urlFor(controller, method, getArgs(method));
}

protected String getContextPath() {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'd rename it to getPrefix(). ContextPath is the implementation.

Turini added a commit that referenced this pull request Aug 11, 2014
Open Linker for extension
@Turini Turini merged commit a39f72e into caelum:master Aug 11, 2014
@Turini
Copy link
Member

Turini commented Aug 11, 2014

thanks @dtelaroli! It'll be released at RC2 version (asap)

@dtelaroli
Copy link
Contributor Author

👍

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants