Fixing php throwing a warning with extract

If the args passed to extract are not an array php throws an error. Added a check to make sure the args are an array before running extract.