Internal emails sent by NASA’s employees revealed just how close Earth got to getting hit by a large asteroid. The documents also confirmed that NASA’s asteroid tracking systems are not 100 percent effective.

The asteroid that was discussed in the emails was 2019 OK. In July, this asteroid surprised NASA after appearing out of nowhere. As indicated in the documents, the asteroid was only spotted about 24 hours before it zoomed past Earth.

According to an email sent by Lindley Johnson, NASA’s planetary defense officer, 2019 OK has an estimated diameter of 187 to 427 feet. It approached the planet from a distance of only 0.00052 astronomical units or around 48,000 miles. This is only about one-fifth the distance between the Earth and the Moon.

Based on the size of the asteroid, it would have certainly triggered a catastrophic event if it collided with the planet.

“Because there may be media coverage tomorrow, I’m alerting you that in about 30 [minutes] a 57-130 meter-sized asteroid will pass Earth at only 0.19 lunar distances (48,000 miles),” Johnson wrote in an email, which was obtained by BuzzFeed News. “2019 OK was spotted about 24 hours ago.”

The other emails between NASA employees centered on possible reasons as to why the asteroid was not detected sooner. In some of the emails, the weather conditions, as well as the positioning of the Moon, were named as some of the factors that hindered 2019 OK’s visibility.

But whatever the real reason is, Paul Chodas of NASA’s Jet Propulsion Laboratory noted that the asteroid simply slipped through NASA’s tracking systems.

“This object slipped through a whole series of our capture nets,” he stated in an email to his colleagues. “I wonder how many times this situation has happened without the asteroid being discovered at all.”

NASA’s failure to spot 2019 OK sooner is certainly alarming especially since the agency has constantly stressed the importance of early detection in preventing an asteroid impact from happening. Hopefully, the space agency will implement better systems that are capable of tracking all asteroids that might approach Earth.