Fixed scroll and added error assertion