File tree Expand file tree Collapse file tree 2 files changed +5
-5
lines changed Expand file tree Collapse file tree 2 files changed +5
-5
lines changed Original file line number Diff line number Diff line change @@ -1153,11 +1153,11 @@ PackageVersionStateInfo _authorizeWorkerCallback(
11531153
11541154 final versionState = state.versions! [version];
11551155 if (versionState == null ) {
1156- throw NotFoundException . resource ( '$ package /$ version ' );
1156+ throw TaskAbortedException ( 'The provided token is invalid or expired. ' );
11571157 }
11581158 // Check the secret token
11591159 if (! versionState.isAuthorized (token)) {
1160- throw AuthenticationException . authenticationRequired ( );
1160+ throw TaskAbortedException ( 'The provided token is invalid or expired.' );
11611161 }
11621162 assert (versionState.scheduled != initialTimestamp);
11631163 assert (versionState.instance != null );
Original file line number Diff line number Diff line change @@ -784,9 +784,9 @@ void main() {
784784 final api = createPubApiClient (authToken: v.token);
785785 await expectApiException (
786786 api.taskUploadFinished ('neon' , v.version),
787- status: 404 ,
788- code: 'NotFound ' ,
789- message: 'Could not find `neon/1.0.0` .' ,
787+ status: 400 ,
788+ code: 'TaskAborted ' ,
789+ message: 'The provided token is invalid or expired .' ,
790790 );
791791 }
792792
You can’t perform that action at this time.
0 commit comments