现在的位置: 首页 > 综合 > 正文

Roles类的小修改

2011年04月28日 ⁄ 综合 ⁄ 共 349字 ⁄ 字号 评论关闭
Roles类中有一个GetRole(Guid roleID, bool cacheable)方法,此处在找不到角色的时候抛出了一个异常
throw new CSException(CSExceptionType.ResourceNotFound, "Role not found: " + roleID.ToString());

此处异常类型为ResourceNotFound,应该改成RoleNotFound类型才对。

throw new CSException(CSExceptionType.RoleNotFound, "Role not found: " + roleID.ToString());

另外一个同样需要修改的方法还有 GetRole(string roleName, bool cacheable)

抱歉!评论已关闭.