Adapt tui generator to the 2024 edition
Code has been adapted on the destination side and now the new generated code cannot be compiled. Apply the same changes to the generator templates. Change-Id: I9fe5e18ba3db240a0adf59c878f8742fb6dfa13a
This commit is contained in:
1 changed files with 2 additions and 2 deletions
@@ -60,7 +60,7 @@ impl From<{{ prefix }}ApiRequest> for ApiRequest {
{%- if mod not in ["list", "show", "get", "delete", "update", "create", "set", "details"] %}
impl From<{{ mod_data.class_name }}> for {{ prefix }}ApiRequest {
fn from(item: {{ mod_data.class_name }}) -> Self {
{{ prefix }}ApiRequest::{{ mod_data.name }}(Box::new({{ mod_data.class_name }}::from(item)))
{{ prefix }}ApiRequest::{{ mod_data.name }}(Box::new(item))
}
}
{%- endif %}
@@ -87,7 +87,7 @@ impl ExecuteApiRequest for {{ prefix }}ApiRequest {
) -> Result<(), CloudWorkerError> {
match self {
{% for mod, mod_data in mod_list|dictsort -%}
{{ prefix }}ApiRequest::{{ mod_data.name }}(ref req) => {
{{ prefix }}ApiRequest::{{ mod_data.name }}(req) => {
req.execute_request(session, request, app_tx).await?;
}
{% endfor %}
Reference in New Issue
Block a user
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.