When I cut/trim boxes down like that, I glue the cut-off/"insert" part to the main box. I feel like this also helps add strength/rigidity to the overall box.
On the "insert": glue on the bottom, glue on the sides, then tape the open "ends" of the main box together to compress everything and keeping the sides of the insert pressing against the main box.
I also glue any closure flaps together when doing final sealing of the box (along with using packing tape). I prefer Elmer's Glue All.
Haven't had a trimmed down box come apart yet, but I've had quite a few "complaints" from people who have had a difficult time opening packages I've shipped them with glued flaps/closures.