Add in better handling for ranges