Scotty McCreery has issued a statement following a recent incident at airport security in his home state of North Carolina. The singer was stopped and given a citation for attempting to bring a loaded handgun through airport security screening -- but it was an accident on his part.

Raleigh's News  & Observer reports that McCreery, 23, was stopped by police at the Raleigh-Durham International Airport around 6PM on July 13 after TSA agents, during a routine security scan, found a loaded handgun in his backpack. Upon further inspection, investigators discovered a black Smith & Wesson handgun loaded with five 9mm rounds and two boxes of ammunition, containing 63 bullets.

For his part, McCreery told police that he had gone to a firing range before heading to the airport and forgot to take the gun out of his backpack. He was cited with a misdemeanor violation for trying to bring the handgun through airport security and board a plane with it.

Country Music Mugshots

After he and his friends were robbed at gunpoint in 2014, McCreery got a concealed carry permit. In a statement made on Friday (July 21), McCreery says that he "take[s] gun safety very seriously" and further explains the airport incident.

"While in between tour dates last week, I went to go target shooting with a friend a few days before an early flight out of my hometown Raleigh-Durham airport. Unfortunately, I did not realize that I left my pistol in my backpack until the TSA found it during the security X-ray screening and rightfully confiscated it," McCreery tells Billboard. "I had my concealed carry permit on me so once they had checked everything out, they then released me to catch the next available flight."

McCreery ends his statement by thanking security personnel -- "great to know our airport security force is on the job," he says -- and by saying the he "[has] learned a lesson that I won’t forget.”

How Well Do You REALLY Know Scotty McCreery?

What Are American Idol's Country Alumni Up to Now?