Skip to content

Commit

Permalink
Improve slack messages
Browse files Browse the repository at this point in the history
  • Loading branch information
Jleagle committed Mar 18, 2019
1 parent 12f2d4d commit 7210d6d
Showing 1 changed file with 14 additions and 3 deletions.
17 changes: 14 additions & 3 deletions Steam.cs
Original file line number Diff line number Diff line change
Expand Up @@ -101,12 +101,23 @@ private static async void CheckForChanges(Object obj, EventArgs args)
// Slack
if (!Config.isLocal())
{
var total = callback.AppChanges.Count + callback.PackageChanges.Count;
if (total >= 100)
if (callback.AppChanges.Count >= 100)
{
try
{
await slack(total + " products queued");
await slack(callback.AppChanges.Count + " apps queued");
}
catch (Exception e)
{
Log.Error(e.ToString());
}
}

if (callback.PackageChanges.Count >= 100)
{
try
{
await slack(callback.PackageChanges.Count + " packages queued");
}
catch (Exception e)
{
Expand Down

0 comments on commit 7210d6d

Please sign in to comment.