Thomas Andrews, 32, of Sunnyvale, California, was arrested Sunday after more than 20,000 rounds of ammunition, several weapons, and body armor were found by authorities conducting a search of his home in response to text messages he sent to his employer, UPS, threatening a mass shooting, NBC News reports.

Police were informed Sunday night that Andrews was planning a mass shooting at the UPS facility in Sunnyvale. When he was found three hours later, a car chase ensued that took them down Highway 101.

Officers escorted Andrews to his apartment where "over 20,000 rounds of handgun and rifle ammunition, numerous high capacity magazines, 5 tactical style rifles, 1 shotgun, 3 handguns and body armor" were discovered. Andrews has been charged with making criminal threats, evading police, driving under the influence, and "several counts of weapons violations." Tactical backpacks with ammunition "staged" at the front door were also found. 

"He alluded to a mass shooting in his text messages," Sunnyvale police Capt. Dan Pistor said, per USA TODAY. "I definitely think we avoided a tragedy." Pistor acknowledges that Andrews was upset with his employer, but was unaware of what specifically he was angry about. 

Also Watch