-
Notifications
You must be signed in to change notification settings - Fork 26
Closed as not planned
Description
Recipe: Finding Content Associated with an Integration
Add a function that takes an integration and returns a list of content items it's associated with.
It would be nice to be able to write:
client <- connect()
integrations <- get_integrations(client)
github_integration <- integrations[1]
get_content(github_integration)To accomplish that, we'd have to do two things:
- Add the Connect client object. Nice to do it as an attribute maybe. Easy.
- Uh… a function named
get_content()already exists, with a very specific signature that kinda precludes doing something likeget_content(x). The first argument is namedsrc.
Ways forward:
- Switch to method dispatch for
get_content()but keep the weird name of the first argumentsrc. People will mostly writeget_content(integration)anyway. - Eat the pain of changing the name of the first argument to
get_content()now. Most people don't pass in the client with a name, I would guess. Use method dispatch. - Name this function something like
get_content_by_integration(). At a later date, make the painful breaking change inget_content(). (Maybe at a point when we're making more breaking changes?)
Metadata
Metadata
Assignees
Labels
No labels