fixed auto patterns, thanks Denes