/** * Create revision. * * @param array $settings * @return null */ protected function create_revision($settings) { $this->revision->__set_array(array('attachment_id' => $this->attachment ? $this->attachment->get_id() : 0, 'revision_name' => $settings['name'], 'revision_version' => $settings['version'], 'revision_status' => TITANIA_REVISION_NEW, 'queue_allow_repack' => $settings['allow_repack'], 'revision_license' => $settings['license'])); $this->revision->set_custom_fields($settings['custom']); $this->revision->phpbb_versions = $settings['vendor_versions']; $this->revision->submit(); $this->id = $this->revision->revision_id; }