Law firms are making profits but caution needed