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

Missing return statement in mojang.account.utils.helpers.get_headers #16

Closed
Lucino772 opened this issue Jan 16, 2022 · 0 comments · Fixed by #17
Closed

Missing return statement in mojang.account.utils.helpers.get_headers #16

Lucino772 opened this issue Jan 16, 2022 · 0 comments · Fixed by #17

Comments

@Lucino772
Copy link
Owner

Lucino772 commented Jan 16, 2022

def get_headers(
json_content: Optional[bool] = False, bearer: Optional[str] = None
):
headers = {}
if json_content:
headers["content-type"] = "application/json"
headers["accept"] = "application/json"
if bearer:
headers["authorization"] = f"Bearer {bearer}"

Lucino772 added a commit that referenced this issue Jan 19, 2022
* ci: PYM-18 Exclude tests folder for mypy

* test: PYM-18 Removed old tests

* test: PYM-18 Added tests for mojang.status

* test: PYM-18 Added tests for mojang.get_uuid

* test: PYM-18 Added tests for mojang.get_uuids

* test: PYM-18 Added tests for mojang.names

* test: PYM-18 Added tests for mojang.user

* fix: Missing return statement in mojang.account.utils.helpers.get_headers (#17)

Fix: #16

* ci: PYM-18 Exclude tests folder for mypy

* test: PYM-18 Removed old tests

* test: PYM-18 Added tests for mojang.status

* test: PYM-18 Added tests for mojang.get_uuid

* test: PYM-18 Added tests for mojang.get_uuids

* test: PYM-18 Added tests for mojang.names

* test: PYM-18 Added tests for mojang.user

* test: PYM-18 Added tests for mojang.account.utils.helpers.get_header

* test: PYM-18 Replaced assertDictContainsSubset with assertDictEqual

* test(tests/): PYM-18 Added MockSessionServer

* test(tests/): PYM-18 Added tests for mojang.account.session.get_user_name_change

* test(tests/): PYM-18 Added tests fro mojang.account.session.change_user_name

* test(tests/): PYM-18 Added tests for mojang.account.session.change_user_skin

* test(tests/): PYM-18 Added tests for mojang.account.session.reset_user_skin

* test(tests/): PYM-18 Added tests for mojang.account.session.show_user_cape

* test(tests/): PYM-18 Added tests for mojang.account.session.hide_user_cape

* test(tests/): PYM-18 Added tests for mojang.account.session.owns_minecraft

* test(tests/): PYM-18 Added tests for mojang.account.session.get_profile
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

Successfully merging a pull request may close this issue.

1 participant