Check if revision is defined at all before comparing