diff options
author | Derf Null <derf@finalrewind.org> | 2023-06-29 21:54:25 +0200 |
---|---|---|
committer | Derf Null <derf@finalrewind.org> | 2023-06-29 21:54:25 +0200 |
commit | a73e2edc8604c8d83c0a85044ca2fc8ef4108bfb (patch) | |
tree | a47f98c57a8860eccba63ed308f7d54486a2a927 /lib | |
parent | 4f54597c0d3f033a0b4f9d6792905218f0b141de (diff) |
profile: use effective visibility from journey object
Diffstat (limited to 'lib')
-rwxr-xr-x | lib/Travelynx/Controller/Profile.pm | 44 |
1 files changed, 20 insertions, 24 deletions
diff --git a/lib/Travelynx/Controller/Profile.pm b/lib/Travelynx/Controller/Profile.pm index c242f58..a6b4a7c 100755 --- a/lib/Travelynx/Controller/Profile.pm +++ b/lib/Travelynx/Controller/Profile.pm @@ -213,9 +213,8 @@ sub profile { follow_reqs_me => ( $inverse_relation and $inverse_relation eq 'requests_follow' ) ? 1 : 0, - journey => $status, - journey_visibility => $visibility, - journeys => [@journeys], + journey => $status, + journeys => [@journeys], ); } @@ -363,14 +362,13 @@ sub journey_details { } $self->render( 'journey', - error => undef, - journey => $journey, - with_map => 1, - username => $name, - readonly => 1, - twitter => \%tw_data, - opengraph => \%og_data, - journey_visibility => $visibility, + error => undef, + journey => $journey, + with_map => 1, + username => $name, + readonly => 1, + twitter => \%tw_data, + opengraph => \%og_data, %{$map_data}, ); } @@ -542,14 +540,13 @@ sub user_status { }, }, any => { - template => 'user_status', - name => $name, - privacy => $user, - journey => $status, - journey_visibility => $visibility, - twitter => \%tw_data, - opengraph => \%og_data, - version => $self->app->config->{version} // 'UNKNOWN', + template => 'user_status', + name => $name, + privacy => $user, + journey => $status, + twitter => \%tw_data, + opengraph => \%og_data, + version => $self->app->config->{version} // 'UNKNOWN', }, ); } @@ -626,11 +623,10 @@ sub status_card { $self->render( '_public_status_card', - name => $name, - privacy => $user, - journey => $status, - journey_visibility => $visibility, - from_profile => $self->param('profile') ? 1 : 0, + name => $name, + privacy => $user, + journey => $status, + from_profile => $self->param('profile') ? 1 : 0, ); } |