<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def update_model(self, tfi):
 """Update the model for the given tfi :param tfi: taskfile info :type tfi: :class:`TaskFileInfo` :returns: None :rtype: None :raises: None """

        if tfi.task.department.assetflag:
            browser = self.assetbrws
        else:
            browser = self.shotbrws

        if tfi.version == 1:  # add descriptor
            parent = browser.selected_indexes(2)[0]
            ddata = treemodel.ListItemData([tfi.descriptor])
            ditem = treemodel.TreeItem(ddata)
            browser.model.insertRow(0, ditem, parent)
        self.set_level(browser, 3, [tfi.descriptor])