The Teamsters union, which has been trying to organize workers at the warehouse, said the closing was retaliation against employees who publicized incidents of sexual harassment and pregnancy discrimination. The group’s organizing efforts there have been underway since 2017, when a worker collapsed and died of cardiac arrest on the warehouse floor.

In October, The Times reported that six women had miscarriages after lifting heavy boxes at the warehouse and being denied breaks from physically intense work. Some of the episodes occurred while the warehouse was operated by another company, New Breed Logistics, which XPO bought in 2014.

Workers at the site lift boxes weighing up to 45 pounds. The facility does not have air-conditioning, and indoor temperatures in the summer can rise past 100 degrees.

“They are just cutting and running and closing the place instead of addressing the problem of pregnancy discrimination and sexual harassment,” Jim Hoffa, the Teamsters president, said in an interview. Mr. Hoffa said the Teamsters were considering filing a formal complaint about the warehouse’s closing with the National Labor Relations Board, the federal agency that handles labor disputes.