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

MBL-1053: Identify if https links in messages are KSR links #1917

Merged
merged 4 commits into from
Dec 14, 2023

Conversation

leighdouglas
Copy link
Contributor

📲 What

Goal is to validate links sent in messages by creators to open app links in-app where applicable.

🤔 Why

Previously, urls sent by creators would always open an external browser. Now, when it is a kickstarter link, it will open in app. All other links will continue to go to an external browser.

🛠 How

  • Update messages view holder and view model to rxjava 2
  • Add functionality to check if textview contains a url
  • Open deeplink activity and supply with url, this will handle the url validation

👀 See

messages-link-validation.mp4

📋 QA

  • Sign-in
  • Go to your messages
  • Find a kickstarter link, tap, should not redirect out of app
  • Find a non-kickstarter link, tap, should redirect to system browser

Story 📖

MBL-1053: Identify if https links in messages are KSR links

Copy link

codecov bot commented Dec 11, 2023

Codecov Report

Attention: 1 lines in your changes are missing coverage. Please review.

Comparison is base (303cad2) 74.29% compared to head (b5d6280) 74.29%.
Report is 1 commits behind head on master.

Files Patch % Lines
...m/kickstarter/viewmodels/MessageHolderViewModel.kt 0.00% 0 Missing and 1 partial ⚠️
Additional details and impacted files
@@            Coverage Diff            @@
##             master    #1917   +/-   ##
=========================================
  Coverage     74.29%   74.29%           
  Complexity     1963     1963           
=========================================
  Files           337      337           
  Lines         19679    19679           
  Branches       2730     2730           
=========================================
  Hits          14620    14620           
  Misses         3491     3491           
  Partials       1568     1568           

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

@leighdouglas leighdouglas marked this pull request as ready for review December 11, 2023 21:41
@leighdouglas leighdouglas self-assigned this Dec 11, 2023
@@ -48,7 +48,7 @@ interface MessageHolderViewModel {
ActivityViewModel<MessageViewHolder?>(environment),
Inputs,
Outputs {
private val currentUser: CurrentUserType?
private val currentUser: CurrentUserTypeV2?
Copy link
Contributor

Choose a reason for hiding this comment

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

very minor, but currentUser cant be null (due to requireNotNull(*)) so it doesn't need to be nullable here

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I'll fix in a subsequent PR! Thanks!

@leighdouglas leighdouglas merged commit d09017f into master Dec 14, 2023
5 checks passed
@leighdouglas leighdouglas deleted the mbl-1053-creator-links branch December 14, 2023 20:28
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.

None yet

3 participants