add length check to liquid