Fixed generator type assumption error

When adding the swift config pieces the dynamic inventory has attempts
to add extra arguments to host _meta inventory which assumes the option
is in a dictionary format. To address the issue an if block  has been
added which which checks the object type and proceeds accordingly.

Closes-Bug: 1399387
Change-Id: I0203dc525ca9e8f962ac683ca07b5cb3bea41589
Merge "Fixed generator type assumption error"