fix quota option
This commit is contained in:
parent
1ff1a23b4f
commit
f23639078b
@ -45,7 +45,7 @@ if [[ -n $quota ]]; then
|
||||
# make quota uppercase in case it is set to NULL
|
||||
quota=`echo $quota | tr [:lower:] [:upper:]`
|
||||
if [[ "$quota" =~ ^[0-9]+$ ]] || [[ "$quota" == "NULL" ]]; then
|
||||
dbset=" mbox_quota_default=$quota"
|
||||
dbset="mbox_quota_default=$quota"
|
||||
else
|
||||
echo "ERROR: quota (-q) must numeric or NULL"
|
||||
exit 1
|
||||
@ -57,7 +57,10 @@ if [[ -n $ratelimit ]]; then
|
||||
# make ratelimit uppercase in case it is set to NULL
|
||||
ratelimit=`echo $ratelimit | tr [:lower:] [:upper:]`
|
||||
if [[ "$ratelimit" =~ ^[0-9]+$ ]] || [[ "$ratelimit" == "NULL" ]]; then
|
||||
dbset=" mbox_ratelimit_default=$ratelimit"
|
||||
if [ ! -z "$dbset" ]; then
|
||||
dbset="$dbset,"
|
||||
fi
|
||||
dbset="$dbset mbox_ratelimit_default=$ratelimit"
|
||||
else
|
||||
echo "ERROR: ratelimit (-r) must numeric or NULL"
|
||||
exit 1
|
||||
|
Loading…
x
Reference in New Issue
Block a user