Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Network
Konversation
Commits
063aab07
Commit
063aab07
authored
Aug 05, 2021
by
Bernd Buschinski
Browse files
Fix uptime reporting with 0 minutes
Wrong Output: "Uptime: 1 hours and minutes" Now: "Uptime: 1 hours and 0 minutes"
parent
3277f11f
Changes
1
Show whitespace changes
Inline
Side-by-side
data/scripts/uptime
View file @
063aab07
...
...
@@ -38,6 +38,8 @@ if($seconds >= 3600)
if
(
$seconds
>
60
)
{
$minutes
=
int
(
$seconds
/
60
);
}
else
{
$minutes
=
0
}
if
(
$days
&&
$hours
)
{
exec
'
qdbus
',
'
org.kde.konversation
',
'
/irc
',
'
say
',
$SERVER
,
$TARGET
,
"
Uptime:
$days
days,
$hours
hours and
$minutes
minutes
";
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a 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