Commit 4c0175e4 authored by Adrian Rossouw's avatar Adrian Rossouw Committed by adrian

Introduce provision_get_option for times when drush_get_option is unavailable

parent 397a885f
......@@ -638,3 +638,14 @@ function provision_exec($cmd, &$data) {
}
};
/**
* A wrapper for drush_get_option for when it is not present
*/
function provision_get_option($option, $default) {
if (function_exists('drush_get_option')) {
return call_user_func('drush_get_option', $option, $default);
}
else {
return $default;
}
}
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment