An ad image from Bebe.

Bebe Stores Inc. is now an affiliate of its lender B. Riley Financial Inc.

The investment bank converted an existing $16.9 million loan with Bebe into 2.82 million shares of common stock at $6 per share and acquired an additional 250,000 shares, which now totals 29 percent of the brand. B. Riley will also control two of Bebe’s five board of director seats.

B. Riley said Bebe “represents an attractive opportunity,” and noted that its intellectual property and licensing revenue totaled $2.9 million during the quarter ended Sept. 30.

“This investment reflects the core strategy of B. Riley Principal Investments which is to invest in companies or corporate assets that present attractive cash flows to generate dividends for shareholders,” Bryant Riley, the firm’s chairman and ceo, said. “By leveraging Bebe’s net operating losses and new tax laws for cash and dividend investments, our focus is to produce attractive investment yields for bebe and B. Riley shareholders.”

B. Riley is set to place its Bebe stake in its subsidiary B. Riley Principal Investments LLC, which also holds United Online Inc. and MagicJack VocalTec, both of which are in the telecomm space.

Manny Mashouf, Bebe founder and its current ceo and chairman, noted that B. Riley’s investment represented a 35 percent premium over the brand’s trading price and that the firms involvement “will provide an added level of strategic direction to our business as well as further stabilization to the investor base.”

Bebe was on the brink of bankruptcy early last year, but managed to avoid it by cutting deals with landlords in order to close all of its store locations and become an online-only brand. The closures were estimated to cost the company about $65 million, but Bebe said it was also in the process of selling owned property, like a distribution center in Benicia, Calif. for $22 million. A design center in Los Angeles valued at $30 million is also for sale.

When the store closures were revealed, Bebe said it had entered in to a $35 million loan agreement with GACP Finance Co. LLC, a subsidiary of B. Riley, in order to make payments to landlords until sales of the buildings close.

Shares of Bebe spiked up nearly 24 percent to $5.50 in early trading Tuesday.

For More, See: To Take Majority Stake in Vietnam’s Tiki

Doug McMillon on Retail’s Only Constant — Change

H&M Temporarily Shutters Stores in South Africa