@@ -323,13 +323,13 @@ fn verify_dependencies(
323
323
324
324
fn transmit (
325
325
gctx : & GlobalContext ,
326
- pkg : & Package ,
326
+ local_pkg : & Package ,
327
327
tarball : & File ,
328
328
registry : & mut Registry ,
329
329
registry_id : SourceId ,
330
330
dry_run : bool ,
331
331
) -> CargoResult < ( ) > {
332
- let deps = pkg
332
+ let deps = local_pkg
333
333
. dependencies ( )
334
334
. iter ( )
335
335
. filter ( |dep| {
@@ -380,7 +380,7 @@ fn transmit(
380
380
} )
381
381
} )
382
382
. collect :: < CargoResult < Vec < NewCrateDependency > > > ( ) ?;
383
- let manifest = pkg . manifest ( ) ;
383
+ let manifest = local_pkg . manifest ( ) ;
384
384
let ManifestMetadata {
385
385
ref authors,
386
386
ref description,
@@ -400,12 +400,13 @@ fn transmit(
400
400
let readme_content = readme
401
401
. as_ref ( )
402
402
. map ( |readme| {
403
- paths:: read ( & pkg. root ( ) . join ( readme) )
404
- . with_context ( || format ! ( "failed to read `readme` file for package `{}`" , pkg) )
403
+ paths:: read ( & local_pkg. root ( ) . join ( readme) ) . with_context ( || {
404
+ format ! ( "failed to read `readme` file for package `{}`" , local_pkg)
405
+ } )
405
406
} )
406
407
. transpose ( ) ?;
407
408
if let Some ( ref file) = * license_file {
408
- if !pkg . root ( ) . join ( file) . exists ( ) {
409
+ if !local_pkg . root ( ) . join ( file) . exists ( ) {
409
410
bail ! ( "the license file `{}` does not exist" , file)
410
411
}
411
412
}
@@ -450,8 +451,8 @@ fn transmit(
450
451
let warnings = registry
451
452
. publish (
452
453
& NewCrate {
453
- name : pkg . name ( ) . to_string ( ) ,
454
- vers : pkg . version ( ) . to_string ( ) ,
454
+ name : local_pkg . name ( ) . to_string ( ) ,
455
+ vers : local_pkg . version ( ) . to_string ( ) ,
455
456
deps,
456
457
features : string_features,
457
458
authors : authors. clone ( ) ,
0 commit comments