Conduit - Add option for createcomment to attach draft inline comments
Summary: Conduit has a query to make a draft inline comment, but createcomment doesn't have the ability to attach them. Added optional parameter to attach any existing draft comments. Default value is false, so existing api users won't be effected by the change. Test Plan: Tested no draft comments and multiple draft comments, attach_inlines =true, false, and empty. Reviewers: vrana Reviewed By: vrana CC: epriestley, aran Differential Revision: https://secure.phabricator.com/D7019
This commit is contained in:
@@ -12,10 +12,11 @@ final class ConduitAPI_differential_createcomment_Method
|
||||
|
||||
public function defineParamTypes() {
|
||||
return array(
|
||||
'revision_id' => 'required revisionid',
|
||||
'message' => 'optional string',
|
||||
'action' => 'optional string',
|
||||
'silent' => 'optional bool',
|
||||
'revision_id' => 'required revisionid',
|
||||
'message' => 'optional string',
|
||||
'action' => 'optional string',
|
||||
'silent' => 'optional bool',
|
||||
'attach_inlines' => 'optional bool',
|
||||
);
|
||||
}
|
||||
|
||||
@@ -52,6 +53,7 @@ final class ConduitAPI_differential_createcomment_Method
|
||||
$editor->setContentSource($content_source);
|
||||
$editor->setMessage($request->getValue('message'));
|
||||
$editor->setNoEmail($request->getValue('silent'));
|
||||
$editor->setAttachInlineComments($request->getValue('attach_inlines'));
|
||||
$editor->save();
|
||||
|
||||
return array(
|
||||
|
||||
Reference in New Issue
Block a user