Commit 079f359 1 parent a36e3aa commit 079f359 Copy full SHA for 079f359
File tree 1 file changed +3
-1
lines changed
1 file changed +3
-1
lines changed Original file line number Diff line number Diff line change @@ -113,6 +113,7 @@ export class DockerImage {
113
113
}
114
114
self . ociImage = response . mediaType === 'application/vnd.oci.image.index.v1+json' ;
115
115
self . layers = response . layers || response . manifests ;
116
+ self . annotations = response . annotations ;
116
117
self . size = self . layers . reduce ( function ( acc , e ) {
117
118
return acc + e . size ;
118
119
} , 0 ) ;
@@ -160,8 +161,9 @@ export class DockerImage {
160
161
oReq . addEventListener ( 'loadend' , function ( ) {
161
162
if ( this . status === 200 || this . status === 202 ) {
162
163
const response = JSON . parse ( this . responseText ) ;
163
- self . creationDate = new Date ( response . created ) ;
164
+ self . creationDate = new Date ( response . created || self . annotations ?. [ 'org.opencontainers.image.created' ] ) ;
164
165
self . blobs = response ;
166
+ self . blobs . history = self . blobs . history || [ ] ;
165
167
self . blobs . history
166
168
. filter ( function ( e ) {
167
169
return ! e . empty_layer ;
You can’t perform that action at this time.
0 commit comments