You have two options:
Option 1: Create a Polymorphic VI. This requires creating 3 VIs. One VI that handles the scalar input, one VI that handles the array input, and one VI that is the polymorphic shell. Then, in your code, you just place the polymorphic VI shell. LabVIEW will call the appropriate version based on the input. To create polymorphic VIs you need the "Professional" edition of LabVIEW. You can find detailed instructions in the online help for LabVIEW.
Option 2: Use variants as inputs.