Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Plasma
Discover
Commits
1942de87
Commit
1942de87
authored
May 22, 2020
by
Aleix Pol Gonzalez
🐧
Browse files
kns: show the release date if the version isn't available
CCBUG: 417192
parent
10b9f259
Changes
1
Hide whitespace changes
Inline
Side-by-side
libdiscover/backends/KNSBackend/KNSResource.cpp
View file @
1942de87
...
...
@@ -140,12 +140,13 @@ int KNSResource::size()
QString
KNSResource
::
installedVersion
()
const
{
return
m_entry
.
version
();
return
!
m_entry
.
version
()
.
isEmpty
()
?
m_entry
.
version
()
:
m_entry
.
releaseDate
().
toString
()
;
}
QString
KNSResource
::
availableVersion
()
const
{
return
!
m_entry
.
updateVersion
().
isEmpty
()
?
m_entry
.
updateVersion
()
:
m_entry
.
updateReleaseDate
().
isEmpty
()
?
m_entry
.
updateReleaseDate
().
toString
()
:
!
m_entry
.
version
().
isEmpty
()
?
m_entry
.
version
()
:
releaseDate
().
toString
();
}
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment