Skip to content

Commit

Permalink
Update itt.ps1
Browse files Browse the repository at this point in the history
  • Loading branch information
emadadel4 committed Nov 21, 2024
1 parent 919a93f commit 2d1389d
Showing 1 changed file with 9 additions and 3 deletions.
12 changes: 9 additions & 3 deletions itt.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -7240,10 +7240,10 @@ function Startup {
# Determine run count and message
if ($existingData) {
$runs = $existingData.runs + 1
Telegram -Message "💻 '$env:USERNAME' has opened ITT again."
#Telegram -Message "💻 '$env:USERNAME' has opened ITT again."
} else {
$runs = 1
Telegram -Message "🎉 A new device 👤 '$env:USERNAME' is now running ITT!"
#Telegram -Message "🎉 A new device 👤 '$env:USERNAME' is now running ITT!"
}

# Update Firebase with the new run count
Expand All @@ -7255,8 +7255,14 @@ function Startup {
$totalKeys = ($response | Get-Member -MemberType NoteProperty | Measure-Object).Count

# Use the same totalKeys for both the Telegram message and Write-Host
Telegram -Message "🌍 Total users worldwide: $totalKeys"
Write-Host "`nITT has been used on $totalKeys devices worldwide.`n" -ForegroundColor White

# Determine run count and message
if ($existingData) {
Telegram -Message "💻 '$env:USERNAME' has opened ITT again."
} else {
Telegram -Message "🎉 A new device 👤 '$env:USERNAME' is now running ITT!`n`🌍 Total users worldwide: $totalKeys"
}

# Force garbage collection to free memory
[System.GC]::Collect()
Expand Down

0 comments on commit 2d1389d

Please sign in to comment.