Skip to content
This repository has been archived by the owner on Oct 24, 2023. It is now read-only.

Commit

Permalink
feat(CustomObject): add constructor using custom object draft
Browse files Browse the repository at this point in the history
Closes #258
  • Loading branch information
Jens Schulze committed Oct 4, 2016

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
1 parent ac487a3 commit 7482d1b
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions src/Request/CustomObjects/CustomObjectCreateRequest.php
Original file line number Diff line number Diff line change
@@ -42,4 +42,14 @@ public static function ofObject($customObject, Context $context = null)
{
return new static($customObject, $context);
}

/**
* @param CustomObjectDraft $customObject
* @param Context|null $context
* @return static
*/
public static function ofDraft(CustomObjectDraft $customObject, Context $context = null)
{
return new static($customObject, $context);
}
}

1 comment on commit 7482d1b

@b3nl
Copy link

@b3nl b3nl commented on 7482d1b Oct 4, 2016

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

thx!

Please # to comment.