Improve check for array defining as as property