Sony Pictures and the team behind the new film "Peter Rabbit" are apologizing after a scene involving a food allergy resulted in criticisms from allergy groups and parents of children with allergies.

Peter Rabbit has garnered mixed reviews from critics, but the new cinematic update of Beatrix Potter’s classic children’s book series is getting a definitive two thumbs down when it comes to a scene involving a food allergy, which some are criticizing as being irresponsible and potentially deadly.

In the scene, Peter Rabbit (voiced by Late Late Show host James Corden) and his animal pals attack a man with blackberries, knowing he’s allergic to them, with the character (played by Domhnall Gleeson) forced to inject his leg with an Epipen.

As The Guardian reports, a number of advocacy groups are taking issue with that scene in the film, with Australia-based Global Anaphylaxis Awareness and Inclusivity (Globalaai) leading the way by launching a petition asking Sony Pictures to apologize, stating the movie “mocks the seriousness of allergic disease and is heartbreakingly disrespectful to the families of those that have lost loved ones to anaphylaxis.”

In addition, U.S. organization Kids with Food Allergies Foundation issued a Facebook post warning parents about film over “food allergy ‘jokes’ are harmful to our community.”

“Making light of this condition hurts our members because it encourages the public not to take the risk of allergic reactions seriously,” added the post, “and this cavalier attitude may make them act in ways that could put an allergic person in danger.”

Sony Pictures and the Peter Rabbit team apologized for the scene in a joint statement published by The Associated Press. They said “food allergies and are a serious issue” and the film “should not have made light” of a character’s allergies “even in a cartoonish, slapstick way.”

The studio and the filmmakers said they, “sincerely regret not being more aware and sensitive to this issue, and we truly apologize.”

Those with food allergies and parents of children with food allergies have started taking to Twitter calling for moviegoers to #BoycottPeterRabbit.

As a mother of a toddler allergic to several foods, I am disgusted that Sony would make a joke out of flicking an allergen at a food allergic individual. Doing so is felony aggravated assault! What kind of message does that scene send to kids?! #boycottpeterrabbit