A magazine-latching assembly for a firearm is described. The magazine-latching assembly includes a latch body that is slideably disposed in a receiver. The latch body includes a notch that accepts an aft tab on a magazine. A locking member is pivotally disposed in the latch body and engages the receiver to lock the latch body in a forward position in which the magazine is locked into the receiver. The assembly includes a magazine-release lever that forms a portion of a trigger guard. Actuation of the magazine-release lever pivots the locking member out of engagement with the receiver, moves the latch body out of engagement with the aft tab of the magazine, and draws the forward tab of the magazine out of engagement with the receiver. The magazine-latching assembly is useable with twin-tab magazines and with bullpup-style firearms. The magazine-release lever is also configured for ambidextrous operation of the firearm.