better scroll check for #514