From 2f7ca23290fd8594128e7de0ee09c30f2c3e2f50 Mon Sep 17 00:00:00 2001 From: chabad360 Date: Wed, 1 Aug 2018 21:25:50 -0700 Subject: [PATCH] Issue was with both messed up if and opposite placement for default --- dbench | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/dbench b/dbench index db7f019c..68a801b5 100644 --- a/dbench +++ b/dbench @@ -32,9 +32,13 @@ if [[ $# -eq 0 ]]; then docker exec -it frappe bash 'bench $@' elif [ $1 == '--init' ]; then - site=$2 - if ! $2; then site="site1.local"; fi - if ! $3; then site="site1.local"; fi + site=$3 + if [ -z "$3" ]; then + site="site1.local" + fi + if [ -z "$2" ]; then + site="site1.local" + fi echo "$site" frappe_installer $site if [ "$2" == '-e' ]; then