diff --git a/lib/portfolio/caller.php b/lib/portfolio/caller.php index bc08ec8dec0..db9a27d819a 100644 --- a/lib/portfolio/caller.php +++ b/lib/portfolio/caller.php @@ -197,7 +197,6 @@ abstract class portfolio_caller_base { public final function set($field, &$value) { if (property_exists($this, $field)) { $this->{$field} =& $value; - $this->dirty = true; return true; } $a = (object)array('property' => $field, 'class' => get_class($this)); diff --git a/lib/portfolio/exporter.php b/lib/portfolio/exporter.php index 142857a63a8..eb12a3d63e1 100644 --- a/lib/portfolio/exporter.php +++ b/lib/portfolio/exporter.php @@ -167,7 +167,6 @@ class portfolio_exporter { $this->instancefile = 'portfolio/' . $this->instance->get('plugin') . '/lib.php'; $this->instance->set('exporter', $this); } - $this->dirty = true; return true; } $a = (object)array('property' => $field, 'class' => get_class($this)); diff --git a/lib/portfolio/formats/leap2a/lib.php b/lib/portfolio/formats/leap2a/lib.php index 48b04d396c2..f19741a8c2c 100644 --- a/lib/portfolio/formats/leap2a/lib.php +++ b/lib/portfolio/formats/leap2a/lib.php @@ -53,9 +53,6 @@ class portfolio_format_leap2a_writer { /** @var stdClass the user exporting data */ private $user; - /** @var string the id of the feed - this is unique to the user and date and used for portfolio ns as well as feed id */ - private $id; - /** @var array the entries for the feed - keyed on id */ private $entries = array(); @@ -68,8 +65,7 @@ class portfolio_format_leap2a_writer { public function __construct(stdclass $user) { // todo something else - exporter, format, etc global $CFG; $this->user = $user; - $this->exporttime = time(); - $this->id = $CFG->wwwroot . '/portfolio/export/leap2a/' . $this->user->id . '/' . $this->exporttime; + $id = $CFG->wwwroot . '/portfolio/export/leap2a/' . $this->user->id . '/' . time(); $this->dom = new DomDocument('1.0', 'utf-8'); @@ -78,11 +74,11 @@ class portfolio_format_leap2a_writer { $this->feed->setAttribute('xmlns:rdf', 'http://www.w3.org/1999/02/22-rdf-syntax-ns#'); $this->feed->setAttribute('xmlns:leap2', 'http://terms.leapspecs.org/'); $this->feed->setAttribute('xmlns:categories', 'http://wiki.leapspecs.org/2A/categories'); - $this->feed->setAttribute('xmlns:portfolio', $this->id); // this is just a ns for ids of elements for convenience + $this->feed->setAttribute('xmlns:portfolio', $id); // This is just a ns for ids of elements for convenience. $this->dom->appendChild($this->feed); - $this->feed->appendChild($this->dom->createElement('id', $this->id)); + $this->feed->appendChild($this->dom->createElement('id', $id)); $this->feed->appendChild($this->dom->createElement('title', get_string('leap2a_feedtitle', 'portfolio', fullname($this->user)))); $this->feed->appendChild($this->dom->createElement('leap2:version', 'http://www.leapspecs.org/2010-07/2A/'));