public function loadHash()
{
- return;
if ($this->hash !== null) {
return;
}
$this->hash = $output;
}
+ public function reloadHash()
+ {
+ $this->hash = null;
+ return $this->loadHash();
+ }
+
/**
* Populates $this->message
*
public function getVc()
{
- return new \VersionControl_Git($this->gitDir);
+ return new \VersionControl_Git($this->workDir);
}
/**
->execute();
$files = explode("\n", trim($output));
foreach ($files as &$file) {
- if ($file{0} == '"') {
+ if ($file[0] == '"') {
$file = $this->decodeFileName($file);
}
}
$link = $this->id . '/delete/confirm';
} else if ($type == 'embed') {
$link = $this->id . '/embed';
+ } else if ($type == 'oembed-json') {
+ $link = 'oembed.php?format=json&url='
+ . urlencode($this->getLink('display', null, true));
+ } else if ($type == 'oembed-xml') {
+ $link = 'oembed.php?format=xml&url='
+ . urlencode($this->getLink('display', null, true));
} else if ($type == 'remotefork') {
return 'web+fork:' . $this->getLink('display', null, true);
} else if ($type == 'revision') {