3 namespace wcf\system\importer
;
5 use wcf\data\conversation\label\ConversationLabel
;
6 use wcf\data\conversation\label\ConversationLabelAction
;
9 * Imports conversation labels.
12 * @copyright 2001-2019 WoltLab GmbH
13 * @license GNU Lesser General Public License <http://opensource.org/licenses/lgpl-license.php>
14 * @package WoltLabSuite\Core\System\Importer
16 class ConversationLabelImporter
extends AbstractImporter
21 protected $className = ConversationLabel
::class;
26 public function import($oldID, array $data, array $additionalData = [])
28 $data['userID'] = ImportHandler
::getInstance()->getNewID('com.woltlab.wcf.user', $data['userID']);
29 if (!$data['userID']) {
33 $action = new ConversationLabelAction([], 'create', [
36 $returnValues = $action->executeAction();
37 $newID = $returnValues['returnValues']->labelID
;
39 ImportHandler
::getInstance()->saveNewID('com.woltlab.wcf.conversation.label', $oldID, $newID);