mirror of
https://we.phorge.it/source/phorge.git
synced 2024-11-22 14:52:41 +01:00
Fix paste (again)
Summary: I messed up D4244 (and didn't test it properly) - this change should load the raw content so we can use it. Test Plan: use the conduit console and actually test the paste conduit methods Reviewers: vrana, epriestley, btrahan Reviewed By: epriestley CC: aran, Korvin Differential Revision: https://secure.phabricator.com/D4245
This commit is contained in:
parent
2f32aebf6f
commit
45b66be96d
3 changed files with 3 additions and 3 deletions
|
@ -57,7 +57,7 @@ final class ConduitAPI_paste_create_Method extends ConduitAPI_paste_Method {
|
|||
$paste->setViewPolicy(PhabricatorPolicies::POLICY_USER);
|
||||
$paste->save();
|
||||
|
||||
$paste->attachContent($content);
|
||||
$paste->attachRawContent($content);
|
||||
|
||||
return $this->buildPasteInfoDictionary($paste);
|
||||
}
|
||||
|
|
|
@ -38,7 +38,7 @@ final class ConduitAPI_paste_info_Method extends ConduitAPI_paste_Method {
|
|||
$paste = id(new PhabricatorPasteQuery())
|
||||
->setViewer($request->getUser())
|
||||
->withIDs(array($paste_id))
|
||||
->needContent(true)
|
||||
->needRawContent(true)
|
||||
->executeOne();
|
||||
if (!$paste) {
|
||||
throw new ConduitException('ERR_BAD_PASTE');
|
||||
|
|
|
@ -30,7 +30,7 @@ final class ConduitAPI_paste_query_Method extends ConduitAPI_paste_Method {
|
|||
protected function execute(ConduitAPIRequest $request) {
|
||||
$query = id(new PhabricatorPasteQuery())
|
||||
->setViewer($request->getUser())
|
||||
->needContent(true);
|
||||
->needRawContent(true);
|
||||
|
||||
if ($request->getValue('ids')) {
|
||||
$query->withIDs($request->getValue('ids'));
|
||||
|
|
Loading…
Reference in a new issue