A function that compares the previous and next session data to determine if it changed and needs to be committed.
The previous session data
The next session data
A boolean indicating if the session should be committed
A function that compares the previous and next session data to determine if it changed and needs to be committed.