Bagehot for beginners: the making of lender-of-last-resort operations in the mid-nineteenth century