File tree 2 files changed +5
-2
lines changed
src/simcore_service_invitations/services
2 files changed +5
-2
lines changed Original file line number Diff line number Diff line change @@ -64,8 +64,7 @@ def _build_link(
64
64
r = URL ("/registration" ).include_query_params (invitation = code_url_safe )
65
65
66
66
# Adds query to fragment
67
- base_url = f"{ base_url } /"
68
- url = URL (base_url ).replace (fragment = f"{ r } " )
67
+ url = URL (f"{ base_url .rstrip ('/' )} /" ).replace (fragment = f"{ r } " )
69
68
return TypeAdapter (HttpUrl ).validate_python (f"{ url } " )
70
69
71
70
Original file line number Diff line number Diff line change @@ -41,6 +41,10 @@ def test_create_invitation(
41
41
assert invitation .guest == invitation_input .guest
42
42
assert invitation .trial_account_days == invitation_input .trial_account_days
43
43
44
+ # checks issue with `//` reported in https://github.com/ITISFoundation/osparc-simcore/issues/7055
45
+ assert invitation .invitation_url
46
+ assert invitation .invitation_url .path == "/"
47
+
44
48
assert invitation .product
45
49
if invitation_input .product :
46
50
assert invitation .product == invitation_input .product
You can’t perform that action at this time.
0 commit comments