Add comment to explain custom side_effect function