change flags to only be alnums to allow arrays to work properly