6:16 AM PT -- 2/21 -- Officials tell TMZ, this is the Taser TSA found in Corey's carry-on. They posted it on social media as a warning to other future passengers.
Corey Feldman allegedly tried to bring a Taser on an airplane in New York ... and he almost got arrested.
Sources close to "The Goonies" star tell TMZ ... Corey was detained Thursday at LaGuardia Airport, after going through a security checkpoint with a Taser.
We're told Corey always travels with a Taser ... which he normally puts in his checked luggage. He's taken it to England and Canada with no issues, but didn't remember he had it on him until it was too late.
Our sources say when Corey went through security, TSA swooped in and detained him. Newsflash for Corey, it's illegal to have a Taser in your carry-on.