Web · Wiki · Activities · Blog · Lists · Chat · Meeting · Bugs · Git · Translate · Archive · People · Donate

Commit a46643064c7b34480f903d82c75bfdd03844db2d

Do not skip license while uploading first version
  
386386 if ($type == 'update') {
387387
388388 // Save License
389 if ($addon['Addon']['dev_agreement'] == true) {
390389 // If we already have an agreement, we didn't show the license
391390 // picker, so use the previously selected license.
392391 global $valid_status;
393392 $old_id = $this->Version->getVersionByAddonId($addon_id, $valid_status);
394393 $oldVersion = $this->Version->findById($old_id);
395394 $license_id = $oldVersion['Version']['license_id'];
396 } else {
395 if (!$license_id) {
397396 $license_id = $this->Developers->saveLicense(
398 $this->data['License'],
399 getitem($this->data, 'License.text'),
400 getitem($this->params, 'form.data.License'));
397 $data['License'],
398 $data['License.text'],
399 $data['form.data.License']);
401400 }
402401 $this->Addon->save(array('Addon' => array('id' => $addon_id,
403402 'dev_agreement' => 1)));
15301530 $this->publish('version', $version['Version']['version']);
15311531 }
15321532
1533 $addon = $this->Addon->getAddon($addon_id, array('default_fields'));
1534 $this->publish('hasAgreement', $addon['Addon']['dev_agreement']);
1533 global $valid_status;
1534 $existed_version = $this->Version->getVersionByAddonId($addon_id, $valid_status);
1535 $this->publish('hasAgreement', $existed_version ? 1 : 0);
15351536
15361537 $this->_uploader();
15371538 }