also add before check to s3