fixing null pointer exception in getwinner