added validation on size limit to 1mb