diff options
author | Alec Warner <antarus@gentoo.org> | 2018-02-26 19:35:20 -0500 |
---|---|---|
committer | Alec Warner <antarus@gentoo.org> | 2018-02-26 19:35:20 -0500 |
commit | 270f219f0d909802a9a9e4fc7aad909a22f35714 (patch) | |
tree | fce2c96516d1fe3a19abe7247b8839628bb2cde3 | |
parent | Fix broken deletion of versions in import code. (diff) | |
download | packages-5-270f219f0d909802a9a9e4fc7aad909a22f35714.tar.gz packages-5-270f219f0d909802a9a9e4fc7aad909a22f35714.tar.bz2 packages-5-270f219f0d909802a9a9e4fc7aad909a22f35714.zip |
Revert "Uniqify versions in the UI for the moment."v6.0.7
This reverts commit 65e1fb72f583e3f3e2ce00bc78ae4d5c6ed45fc6.
We need to test our indexer fix, we will do this on master and push
ptest to 6.0.7 to verify.
-rw-r--r-- | app/models/package.rb | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/app/models/package.rb b/app/models/package.rb index ea7d871..7ad3cbe 100644 --- a/app/models/package.rb +++ b/app/models/package.rb @@ -47,16 +47,13 @@ class Package @versions ||= Version.find_all_by(:package, atom, sort: { sort_key: { order: 'asc' } }) end - def unique_versions - versions.uniq { |v| v.version } - end - def latest_version versions.first end def version(version_str) versions.each { |version| return version if version.version == version_str } + nil end |