From 6789098bc56a230505a24e4fdbb353d753991b68 Mon Sep 17 00:00:00 2001 From: Jonathan Mainguy Date: Fri, 18 Jul 2014 09:52:37 -0400 Subject: [PATCH] This fixes 8173, if target was not defined it would break, now it wont --- library/database/mysql_db | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/library/database/mysql_db b/library/database/mysql_db index 184c30381c..36ba6369e8 100644 --- a/library/database/mysql_db +++ b/library/database/mysql_db @@ -283,7 +283,8 @@ def main(): target = module.params["target"] # make sure the target path is expanded for ~ and $HOME - target = os.path.expandvars(os.path.expanduser(target)) + if target is not None: + target = os.path.expandvars(os.path.expanduser(target)) # Either the caller passes both a username and password with which to connect to # mysql, or they pass neither and allow this module to read the credentials from