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

fix(turbopack): Fix deprecation warnings from unnecessary .to_resolved() calls #73631

Merged
merged 1 commit into from
Dec 9, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions crates/next-core/src/next_app/app_client_references_chunks.rs
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ pub async fn get_app_client_references_chunks(

(
(
client_chunk_group.assets.to_resolved().await?,
client_chunk_group.assets,
client_chunk_group.availability_info,
),
if let Some(ssr_chunking_context) = ssr_chunking_context {
Expand All @@ -88,7 +88,7 @@ pub async fn get_app_client_references_chunks(
.await?;

Some((
ssr_chunk_group.assets.to_resolved().await?,
ssr_chunk_group.assets,
ssr_chunk_group.availability_info,
))
} else {
Expand All @@ -103,7 +103,7 @@ pub async fn get_app_client_references_chunks(

(
(
client_chunk_group.assets.to_resolved().await?,
client_chunk_group.assets,
client_chunk_group.availability_info,
),
None,
Expand Down
6 changes: 2 additions & 4 deletions turbopack/crates/turbopack-core/src/chunk/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -404,9 +404,7 @@ async fn graph_node_to_referenced_nodes(
return Ok((
Some(ChunkGraphEdge {
key: None,
node: ChunkContentGraphNode::ExternalModuleReference(
reference.to_resolved().await?,
),
node: ChunkContentGraphNode::ExternalModuleReference(reference),
}),
None,
));
Expand Down Expand Up @@ -622,7 +620,7 @@ async fn chunk_content_internal_parallel(
return Ok(None);
};
Ok(Some(ChunkGraphEdge {
key: Some(entry.to_resolved().await?),
key: Some(entry),
node: ChunkContentGraphNode::ChunkItem {
item: chunkable_module.as_chunk_item(chunking_context),
ident: chunkable_module.ident().to_string().await?,
Expand Down
5 changes: 0 additions & 5 deletions turbopack/crates/turbopack-core/src/issue/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -637,11 +637,6 @@ async fn source_pos(
return Ok(None);
};

let (content_1, content_2) = (
content_1.to_resolved().await?,
content_2.to_resolved().await?,
);

if content_1 != content_2 {
return Ok(None);
}
Expand Down
3 changes: 0 additions & 3 deletions turbopack/crates/turbopack-core/src/source_map/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -502,9 +502,6 @@ impl SourceMap {
.await?;
sections.push(SourceMapSection::new(section.offset, map));
}
for section in &mut sections {
section.map = section.map.to_resolved().await?;
}
SourceMap::new_sectioned(sections)
}
}
Expand Down
2 changes: 1 addition & 1 deletion turbopack/crates/turbopack-css/src/asset.rs
Original file line number Diff line number Diff line change
Expand Up @@ -233,7 +233,7 @@ impl CssChunkItem for CssModuleChunkItem {
Vc::try_resolve_downcast::<Box<dyn CssChunkItem>>(item).await?
{
imports.push(CssImport::Internal(
import_ref.to_resolved().await?,
import_ref,
css_item.to_resolved().await?,
));
}
Expand Down
Loading