Prevent Exception if boolean value is passed

In some cases, a Boolean value is passed, which array-merge can not handle.