Build fix - user quota size setting methods in People API now only accept a string value.

git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@14128 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
Kevin Roast
2009-04-30 07:40:49 +00:00
parent d4e4aeeaa3
commit fdc6191718

View File

@@ -333,25 +333,13 @@ public final class People extends BaseScopableProcessorExtension
* Only the admin authority can set this value. * Only the admin authority can set this value.
* *
* @param person Person to set quota against. * @param person Person to set quota against.
* @param quota In bytes, a value of -1 means no quota is set * @param quota As a string, in bytes, a value of "-1" means no quota is set
*/ */
public void setQuota(ScriptNode person, Integer quota) public void setQuota(ScriptNode person, String quota)
{
setQuota(person, quota.longValue());
}
/**
* Set the content quota in bytes for a person.
* Only the admin authority can set this value.
*
* @param person Person to set quota against.
* @param quota In bytes, a value of -1 means no quota is set
*/
public void setQuota(ScriptNode person, Long quota)
{ {
if (this.authorityService.isAdminAuthority(AuthenticationUtil.getFullyAuthenticatedUser())) if (this.authorityService.isAdminAuthority(AuthenticationUtil.getFullyAuthenticatedUser()))
{ {
this.contentUsageService.setUserQuota((String)person.getProperties().get(ContentModel.PROP_USERNAME), quota); this.contentUsageService.setUserQuota((String)person.getProperties().get(ContentModel.PROP_USERNAME), Long.parseLong(quota));
} }
} }