Fixed bug with -r option that wasn't taken into account