You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@roller.apache.org by sn...@apache.org on 2006/10/03 23:57:30 UTC
svn commit: r452647 -
/incubator/roller/trunk/src/org/apache/roller/ui/authoring/struts/actions/InvitationsAction.java
Author: snoopdave
Date: Tue Oct 3 14:57:30 2006
New Revision: 452647
URL: http://svn.apache.org/viewvc?view=rev&rev=452647
Log:
Catch and report error sending revoke notice
Modified:
incubator/roller/trunk/src/org/apache/roller/ui/authoring/struts/actions/InvitationsAction.java
Modified: incubator/roller/trunk/src/org/apache/roller/ui/authoring/struts/actions/InvitationsAction.java
URL: http://svn.apache.org/viewvc/incubator/roller/trunk/src/org/apache/roller/ui/authoring/struts/actions/InvitationsAction.java?view=diff&rev=452647&r1=452646&r2=452647
==============================================================================
--- incubator/roller/trunk/src/org/apache/roller/ui/authoring/struts/actions/InvitationsAction.java (original)
+++ incubator/roller/trunk/src/org/apache/roller/ui/authoring/struts/actions/InvitationsAction.java Tue Oct 3 14:57:30 2006
@@ -113,8 +113,8 @@
Roller roller = RollerFactory.getRoller();
UserManager umgr = roller.getUserManager();
PermissionsData perms = umgr.getPermissions(invitationForm.getPermissionId());
+ ActionErrors errors = new ActionErrors();
if (perms == null) {
- ActionErrors errors = new ActionErrors();
errors.add(null, new ActionError("invitations.error.notFound"));
saveErrors(request, errors);
return view(mapping, actionForm, request, response);
@@ -123,7 +123,12 @@
if (rses.isUserAuthorizedToAdmin(perms.getWebsite())) {
umgr.removePermissions(perms);
roller.flush();
- notifyInvitee(request, perms.getWebsite(), perms.getUser());
+ try {
+ notifyInvitee(request, perms.getWebsite(), perms.getUser());
+ } catch (RollerException e) {
+ errors.add(ActionErrors.GLOBAL_ERROR,
+ new ActionError("error.untranslated", e.getMessage()));
+ }
ActionMessages msgs = new ActionMessages();
msgs.add(ActionMessages.GLOBAL_MESSAGE,
new ActionMessage("invitations.revoked"));