Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Make endpoints.py more DRY #827

Closed
miketaylr opened this issue Nov 11, 2015 · 0 comments
Closed

Make endpoints.py more DRY #827

miketaylr opened this issue Nov 11, 2015 · 0 comments
Assignees

Comments

@miketaylr
Copy link
Member

Right now endpoints.py is full of a ton of duplicated code that looks like this:

if g.user:
   do_something(some, args, here)
else:
   proxy_something(slightly, different, args)

It's kind of gross. Let's make it less gross. 💩

@miketaylr miketaylr self-assigned this Nov 11, 2015
miketaylr pushed a commit that referenced this issue Nov 11, 2015
Part of this means we're always sending request headers to GitHub
and always returning response headers from GitHub. Before it
was only in some places. This might break things, or it might
make them better!
miketaylr pushed a commit that referenced this issue Nov 11, 2015
Part of this means we're always sending request headers to GitHub
and always returning response headers from GitHub. Before it
was only in some places. This might break things, or it might
make them better!
miketaylr pushed a commit that referenced this issue Nov 13, 2015
Also, update some of the comments in api_request helper method.
miketaylr pushed a commit that referenced this issue Nov 13, 2015
This already happens in api_request.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants