Set the config Kibana document depending on the version

The patch allows to define the Kibana version within pillar

Change-Id: Ifa89a56e35ed6d9bedbec0a2d847a3b9c926b7e4
diff --git a/_states/kibana_object.py b/_states/kibana_object.py
index ca0a133..e8ac651 100644
--- a/_states/kibana_object.py
+++ b/_states/kibana_object.py
@@ -50,9 +50,7 @@
         ret['comment'] = 'Content is not set'
         return ret
 
-    profile = __salt__['config.option']('kibana')
-
-    url, index = _set_parameters(name, kibana_type, profile)
+    url, index = _get_parameters(name, kibana_type)
     if not url:
         ret['result'] = False
         ret['comment'] = index
@@ -89,9 +87,7 @@
     '''
     ret = {'name': name, 'result': True, 'comment': '', 'changes': {}}
 
-    profile = __salt__['config.option']('kibana')
-
-    url, index = _set_parameters(name, kibana_type, profile)
+    url, index = _get_parameters(name, kibana_type)
     if not url:
         ret['result'] = False
         ret['comment'] = index
@@ -116,7 +112,7 @@
     return ret
 
 
-def _set_parameters(name, kibana_type, profile):
+def _get_parameters(name, kibana_type):
     '''
     Retrieve parameters from profile.
     '''
@@ -124,6 +120,8 @@
     if not kibana_type:
         return False, 'Type is not set'
 
+    profile = __salt__['config.option']('kibana')
+
     url = profile.get('kibana_url')
     if not url:
         return False, 'Cannot get URL needed by Kibana client'