refactored the wager recording solution