Refactoring - staff to system (and small bug fix)