small fix to Seans code