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

Remove some depricated code pointed in #2655; #2808

Conversation

mat1th
Copy link
Contributor

@mat1th mat1th commented Jun 3, 2024

Summary

In issue #2655 there is some code referenced that is not needed anymore. So I've removed it.

Screenshots

The app still launches on a iPhone simulator. Could not test the macOS target.

Link to pull request in Documentation repository

Documentation: home-assistant/companion.home-assistant#

Any other notes

@mat1th mat1th force-pushed the feature/remove-depricated-and-not-used-code branch from 0128652 to 7b810bc Compare June 3, 2024 18:19
@@ -293,7 +293,7 @@ extension NotificationManager: UNUserNotificationCenterDelegate {
return
}

var methods: UNNotificationPresentationOptions = [.alert, .badge, .sound]
Copy link
Contributor Author

Choose a reason for hiding this comment

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

Copy link
Member

@bgoncal bgoncal Jun 7, 2024

Choose a reason for hiding this comment

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

Perhaps we should follow the deprecation message?
"
Deprecated
Use list and banner instead.
"

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Good point, I've added them.

@@ -104,7 +104,7 @@ class IncomingURLHandler {
pipeline: pipeline?.identifier ?? "",
autoStartRecording: autoStartRecording
)
case let .rejected(error):
case .rejected:
Copy link
Contributor Author

Choose a reason for hiding this comment

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

Error value was not used;

Copy link
Member

@bgoncal bgoncal Jun 4, 2024

Choose a reason for hiding this comment

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

Perhaps this instead:
Current.Log.error("Failed to obtain webview to open Assist In App: \(error.localizedDescription)")

@bgoncal
Copy link
Member

bgoncal commented Jun 4, 2024

Thank you!
For the linter:
bundle exec fastlane autocorrect

Copy link

codecov bot commented Jun 4, 2024

Codecov Report

Attention: Patch coverage is 0% with 3 lines in your changes missing coverage. Please review.

Project coverage is 28.40%. Comparing base (6c34210) to head (141c31c).
Report is 135 commits behind head on master.

Current head 141c31c differs from pull request most recent head bb3a119

Please upload reports for the commit bb3a119 to get more accurate results.

Files Patch % Lines
...ources/App/Notifications/NotificationManager.swift 0.00% 1 Missing ⚠️
Sources/App/WebView/IncomingURLHandler.swift 0.00% 1 Missing ⚠️
Sources/App/WebView/WebViewController.swift 0.00% 1 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##           master    #2808      +/-   ##
==========================================
+ Coverage   27.54%   28.40%   +0.85%     
==========================================
  Files         311      360      +49     
  Lines       31699    24536    -7163     
==========================================
- Hits         8733     6970    -1763     
+ Misses      22966    17566    -5400     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@mat1th mat1th requested a review from bgoncal June 6, 2024 16:35
@mat1th mat1th force-pushed the feature/remove-depricated-and-not-used-code branch from 1afe1f4 to 3e49cca Compare June 6, 2024 17:20
Copy link
Member

@bgoncal bgoncal left a comment

Choose a reason for hiding this comment

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

Looks good to me, I'll run some manual tests just to be sure

Copy link
Member

@bgoncal bgoncal left a comment

Choose a reason for hiding this comment

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

Tested and all looks good, just this suggestion above, let me know what you think

@home-assistant home-assistant bot marked this pull request as draft June 7, 2024 14:59
@home-assistant
Copy link

home-assistant bot commented Jun 7, 2024

Please take a look at the requested changes, and use the Ready for review button when you are done, thanks 👍

Learn more about our pull request process.

@mat1th mat1th marked this pull request as ready for review June 8, 2024 06:38
@home-assistant home-assistant bot requested a review from bgoncal June 8, 2024 06:38
@bgoncal bgoncal merged commit d5fe2ee into home-assistant:master Jun 10, 2024
4 checks passed
@bgoncal
Copy link
Member

bgoncal commented Jun 10, 2024

Thank you!

@mat1th mat1th deleted the feature/remove-depricated-and-not-used-code branch June 10, 2024 08:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants