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

chore: make a single switcherapi class #809

Merged
merged 2 commits into from
Nov 18, 2024

Conversation

YogevBokobza
Copy link
Collaborator

@YogevBokobza YogevBokobza commented Nov 11, 2024

Description

BREAKING CHANGE: Convert SwitcherType1Api and SwitcherType2Api to a single SwitcherApi class.

Related issue (if any): fixes #778

Checklist

  • I have followed this repository's contributing guidelines.
  • I will adhere to the project's code of conduct.

@pull-request-size pull-request-size bot added the size: l Pull request has 100 to 500 lines label Nov 11, 2024
@auto-me-bot auto-me-bot bot added the status: needs review Pull request needs a review label Nov 11, 2024
@YogevBokobza
Copy link
Collaborator Author

Does adding "IF"s to each function make sense to allow the function to run only for a specific device type?
I mean this function "stop_shutter(..)" is meant for Type2 devices and not Type1. Should we block accessing Type1 devices for this function?

@auto-me-bot auto-me-bot bot added status: review started Pull review in progress and removed status: needs review Pull request needs a review labels Nov 11, 2024
@thecode
Copy link
Collaborator

thecode commented Nov 12, 2024

Does adding "IF"s to each function make sense to allow the function to run only for a specific device type? I mean this function "stop_shutter(..)" is meant for Type2 devices and not Type1. Should we block accessing Type1 devices for this function?

I don't think we should complicate the implementation with this

@YogevBokobza
Copy link
Collaborator Author

Does adding "IF"s to each function make sense to allow the function to run only for a specific device type? I mean this function "stop_shutter(..)" is meant for Type2 devices and not Type1. Should we block accessing Type1 devices for this function?

I don't think we should complicate the implementation with this

Fine by me.

@auto-me-bot auto-me-bot bot added status: approved Pull request is approved and removed status: review started Pull review in progress labels Nov 12, 2024
@TomerFi TomerFi changed the title feat: make a single switcherapi class chore: make a single switcherapi class Nov 18, 2024
@TomerFi TomerFi merged commit 9478289 into TomerFi:dev Nov 18, 2024
10 checks passed
@auto-me-bot auto-me-bot bot added status: merged Pull request merged and removed status: approved Pull request is approved labels Nov 18, 2024
@TomerFi
Copy link
Owner

TomerFi commented Nov 18, 2024

Thank you very much!
Merged and released: 5.0.0.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
size: l Pull request has 100 to 500 lines status: merged Pull request merged
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Refactor API Instantiation
3 participants