Conor McGregor will face no charges from Irish authorities after he posted a photo featuring an airsoft gun a couple of weeks ago that could have potentially landed him in hot water.

McGregor immediately apologized after police were notified and began to look into the matter because of Ireland's strict gun laws that make brandishing a firearm -- even a pellet gun -- possibly illegal.

FOX Sports first reported that McGregor was cooperating with police and wasn't expected to face any charges from the incident, and TMZ confirmed with Irish authorities on Tuesday that the investigation was officially closed.

McGregor later apologized for the incident and stated that he was actually just prepping for a potential movie role when he took the photo and then posted it on Instagram.

McGregor has been offered a part in Vin Diesel's upcoming movie "xXx: The Return of Xander Cage," although the UFC featherweight champion hasn't officially accepted the role.

McGregor is in Los Angeles ahead of a news conference in Las Vegas on Wednesday to begin the promotion for his next fight at UFC 197.

McGregor faces Rafael dos Anjos with the lightweight title on the line, attempting to become the first fighter to hold two belts in the UFC simultaneously.