Skip to content

Commit 7ea127f

Browse files
author
Marcos
committed
Fix suspend mail account quota
1 parent 7ab3fef commit 7ea127f

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

bin/v-suspend-mail-account

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -47,6 +47,9 @@ is_object_unsuspended "mail/$domain" 'ACCOUNT' "$account"
4747

4848
if [[ "$MAIL_SYSTEM" =~ exim ]]; then
4949
quota=$(get_object_value "mail/$domain" 'ACCOUNT' "$account" '$QUOTA')
50+
if [ "$quota" = 'unlimited' ]; then
51+
quota=0
52+
fi
5053
sed -i "/^$account:/d" $HOMEDIR/$user/conf/mail/$domain/passwd
5154
str="$account:SUSPENDED:$user:mail::$HOMEDIR/$user:$quota"
5255
echo $str >> $HOMEDIR/$user/conf/mail/$domain/passwd

0 commit comments

Comments
 (0)