Browse code

use deprecated function instead of modifying global

It's safer to run this through a common function to let us make
changes later.

Change-Id: Ic661824027577e1946726c1843a29ac8325915bf

Sean Dague authored on 2015/10/08 00:51:40
Showing 2 changed files
... ...
@@ -341,7 +341,7 @@ function use_database {
341 341
         # No backends registered means this is likely called from ``localrc``
342 342
         # This is now deprecated usage
343 343
         DATABASE_TYPE=$1
344
-        DEPRECATED_TEXT="$DEPRECATED_TEXT\nThe database backend needs to be properly set in ENABLED_SERVICES; use_database is deprecated localrc\n"
344
+        deprecated "The database backend needs to be properly set in ENABLED_SERVICES; use_database is deprecated localrc"
345 345
     else
346 346
         # This should no longer get called...here for posterity
347 347
         use_exclusive_service DATABASE_BACKENDS DATABASE_TYPE $1
... ...
@@ -93,7 +93,7 @@ if [[ -n $CINDER_SECURE_DELETE ]]; then
93 93
     if [[ $CINDER_SECURE_DELETE == "False" ]]; then
94 94
         CINDER_VOLUME_CLEAR_DEFAULT="none"
95 95
     fi
96
-    DEPRECATED_TEXT="$DEPRECATED_TEXT\nConfigure secure Cinder volume deletion using CINDER_VOLUME_CLEAR instead of CINDER_SECURE_DELETE.\n"
96
+    deprecated "Configure secure Cinder volume deletion using CINDER_VOLUME_CLEAR instead of CINDER_SECURE_DELETE."
97 97
 fi
98 98
 CINDER_VOLUME_CLEAR=${CINDER_VOLUME_CLEAR:-${CINDER_VOLUME_CLEAR_DEFAULT:-zero}}
99 99
 CINDER_VOLUME_CLEAR=$(echo ${CINDER_VOLUME_CLEAR} | tr '[:upper:]' '[:lower:]')