Skip to content

Commit

Permalink
Remove is_prerelease declaration when not needed
Browse files Browse the repository at this point in the history
  • Loading branch information
GuillaumeGomez committed Sep 9, 2024
1 parent 3f7b692 commit d21408a
Show file tree
Hide file tree
Showing 5 changed files with 1 addition and 5 deletions.
1 change: 0 additions & 1 deletion templates/crate/builds.html
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,6 @@
{%- set target = "" -%}
{%- set inner_path = metadata.target_name_url() -%}
{%- set is_latest_version = true -%}
{%- set is_prerelease = false -%}
{%- include "rustdoc/topbar.html" -%}
{%- endblock topbar -%}

Expand Down
1 change: 0 additions & 1 deletion templates/crate/details.html
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@
{%- block topbar -%}
{%- set inner_path = metadata.target_name_url() -%}
{%- set is_latest_version = true -%}
{%- set is_prerelease = false -%}
{%- include "rustdoc/topbar.html" -%}
{%- endblock topbar -%}

Expand Down
1 change: 0 additions & 1 deletion templates/crate/features.html
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@
{%- set target = "" -%}
{%- set inner_path = metadata.target_name_url() -%}
{%- set is_latest_version = true -%}
{%- set is_prerelease = false -%}
{%- include "rustdoc/topbar.html" -%}
{%- endblock topbar -%}

Expand Down
1 change: 0 additions & 1 deletion templates/crate/source.html
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@
{%- set target = "" -%}
{%- set inner_path = metadata.target_name_url() -%}
{%- set is_latest_version = true -%}
{%- set is_prerelease = false -%}
{%- include "rustdoc/topbar.html" -%}
{%- endblock topbar -%}

Expand Down
2 changes: 1 addition & 1 deletion templates/rustdoc/topbar.html
Original file line number Diff line number Diff line change
Expand Up @@ -194,7 +194,7 @@
{%- if yanked -%}
{%- set tooltip = "You are seeing a yanked version of the {} crate. Click here to go to the latest version."|format(metadata.name) -%}
{%- set title = "This release has been yanked, go to latest version" -%}
{%- elif is_prerelease -%}
{%- elif is_prerelease is defined && is_prerelease -%}
{%- set tooltip = "You are seeing a pre-release version of the {} crate. Click here to go to the latest stable version."|format(metadata.name) -%}
{%- set title = "Go to latest stable release" -%}
{%- else -%}
Expand Down

0 comments on commit d21408a

Please sign in to comment.