Index: api/SMWWriter_API.php =================================================================== --- api/SMWWriter_API.php (revision 68602) +++ api/SMWWriter_API.php (working copy) @@ -44,7 +44,7 @@ $remove = $params['remove']; $flags = $params['flags']; $summary = $params['summary']; - + echo "

Title: " . $params['title'] . "

"; // TODO: Remove $titleObj = Title::newFromText($params['title']); if(!$titleObj || $titleObj->isExternal()) $this->dieUsageMsg(array('invalidtitle', $params['title'])); Index: api/SMWWriter.php =================================================================== --- api/SMWWriter.php (revision 68602) +++ api/SMWWriter.php (working copy) @@ -79,7 +79,7 @@ $count = count( $values ); $without = null; for ( $i = 0; $i < $count; $i++ ) - if ($values[$i]->getHash() === $value->getHash()) { + if ($values[$i] != '' && $values[$i]->getHash() === $value->getHash()) { unset( $this->data[$propertyname][$i] ); break; } @@ -120,11 +120,11 @@ public function copySemanticData( SMWSemanticData $data ) { $properties = $data->getProperties(); foreach ( $properties as $property ) { - if ( $property->isUserDefined() ) { + // if ( $property->isUserDefined() ) { // TODO: Check with Denny what to do with this // SHL $values = $data->getPropertyValues($property); foreach ( $values as $value ) $this->addPropertyValue($property, $value); - } + // } // TODO: Check with Denny what to do with this // SHL } } @@ -506,12 +506,12 @@ * @return boolean true if everything is OK */ private function checkSubject(Title $remove, Title $add) { - if ( !$add->equals($this->title) ) return false; - if ( $remove->exists() ) { - if ( !$remove->equals($this->title) ) return false; - } else { - $this->nosubject = true; - } + // TODO: Check how this one should look + if ( $remove->exists() ) { + if ( !$remove->equals($this->title) ) return false; // TODO: Check with Denny what to do with this + } else { + if ( !$add->equals($this->title) ) return false; + } return true; }