File tree Expand file tree Collapse file tree 2 files changed +10
-0
lines changed Expand file tree Collapse file tree 2 files changed +10
-0
lines changed Original file line number Diff line number Diff line change 44
55import 'package:pub_dev/package/backend.dart' ;
66
7+ import '../../account/backend.dart' ;
8+ import '../../account/models.dart' ;
79import 'actions.dart' ;
810
911final packageInfo = AdminAction (
@@ -27,11 +29,18 @@ Loads and displays the package information.
2729 throw NotFoundException .resource (package);
2830 }
2931
32+ final uploaderIds = p.uploaders;
33+ List <User >? uploaders;
34+ if (uploaderIds != null ) {
35+ uploaders =
36+ (await accountBackend.lookupUsersById (uploaderIds)).nonNulls.toList ();
37+ }
3038 return {
3139 'package' : {
3240 'name' : p.name,
3341 'created' : p.created? .toIso8601String (),
3442 'publisherId' : p.publisherId,
43+ 'uploaders' : uploaders? .map ((u) => u.email).toList (),
3544 'latestVersion' : p.latestVersion,
3645 'isModerated' : p.isModerated,
3746 if (p.moderatedAt != null )
Original file line number Diff line number Diff line change @@ -23,6 +23,7 @@ void main() {
2323 'name' : 'oxygen' ,
2424 'created' : isNotEmpty,
2525 'publisherId' : null ,
26+ 'uploaders' : [
'[email protected] ' ],
2627 'latestVersion' : '1.2.0' ,
2728 'isModerated' : false ,
2829 }
You can’t perform that action at this time.
0 commit comments