Merge "If plugin is enabled multiple times fail" into stable/newton

This commit is contained in:
Jenkins 2017-07-28 01:50:52 +00:00 committed by Gerrit Code Review
commit 5832da784b
1 changed files with 3 additions and 0 deletions

View File

@ -1779,6 +1779,9 @@ function enable_plugin {
local name=$1
local url=$2
local branch=${3:-master}
if [[ ",${DEVSTACK_PLUGINS}," =~ ,${name}, ]]; then
die $LINENO "Plugin attempted to be enabled twice: ${name} ${url} ${branch}"
fi
DEVSTACK_PLUGINS+=",$name"
GITREPO[$name]=$url
GITDIR[$name]=$DEST/$name