public function prepend($path, $contents) { try { $this->fs->update($path, $contents . $this->fs->read($path)); return; } catch (Error $ex) { } catch (Exception $ex) { } throw new WriteException("File {$path} could not be prepended.", $ex); }