Refactored decision function in nottingham.py