Skip to content

Commit af020c0

Browse files
blackheavenandreasabel
authored andcommitted
Fix lastVersion update in listings
1 parent 70b2934 commit af020c0

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

src/Distribution/Server/Features/PackageList.hs

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -134,7 +134,10 @@ initListFeature _env = do
134134

135135
registerHookJust packageChangeHook isPackageAdd $ \pkg -> do
136136
let pkgname = packageName . packageId $ pkg
137-
modifyItem pkgname (\x -> x {itemLastUpload = fst (pkgOriginalUploadInfo pkg)})
137+
modifyItem pkgname $ \x -> x
138+
{itemLastUpload = fst (pkgOriginalUploadInfo pkg)
139+
,itemLastVersion = prettyShow $ pkgVersion $ pkgInfoId pkg
140+
}
138141
runHook_ itemUpdate (Set.singleton pkgname)
139142

140143
registerHook groupChangedHook $ \(gd,_,_,_,_) ->

0 commit comments

Comments
 (0)