# Making join/leave log more useful

By
Leo
Published 2022-12-26

Today we've rolled out an update changing when join and leave logs are displayed.

Previously, if an account was kicked or banned immediately afer joining (due to ban sync, antiraid or other components) the join message would be suppressed and only a User has been kicked/banned. message was displayed.

It was often hard to differentiate if the user who got kicked or banned just joined or was a veteran.

Now we will log the join always even if the user is kicked or banned immediately after.

Additionally, previously The Cleaner would log the user being kicked or banned and the leave event which is redundant. Now The Cleaner is suppressing the leave event if the user was kicked or banned by The Cleaner (kicks/bans by other bots or users will still get logged).

# Examples

00:00:00 @User-1 (User-1#0000) joined. (age=6m 9s)

01:00:00 @User-2 (User-2#0000) has been kicked.
 Reason  Ban Sync
01:00:01 @User-2 (User-2#0000) left.

02:00:00 @User-3 (User-3#0000) joined. (age=4h 2m 0s)
02:00:10 @User-3 Deleted message by (User-3#0000) in #general.
 Reason  Automod.
02:00:10 @User-3 (User-3#0000) has been kicked.
 Reason  Automod.
02:00:11 @User-3 (User-3#0000) left.

03:00:00 @User-1 (User-1#0000) left.
00:00:00 @User-1 (User-1#0000) joined. (age=6m 9s)

01:00:00 @User-2 (User-2#0000) joined. (age=10d)
01:00:00 @User-2 (User-2#0000) has been kicked.
 Reason  Ban Sync

02:00:00 @User-3 (User-3#0000) joined. (age=4h 2m 0s)
02:00:10 @User-3 Deleted message by (User-3#0000) in #general.
 Reason  Automod.
02:00:10 @User-3 (User-3#0000) has been kicked.
 Reason  Automod.

03:00:00 @User-1 (User-1#0000) left.

# Updated join log information

Previously, The Cleaner showed account creation time with day precision if the account was older than two days and with hour precision if not.

Now, The Cleanre is showing creation time precise to the second if the account is not older than three days.

00:00:00 @User-1 (User-1#000) joined. (age=0.0 hours, risk=100)
00:00:00 @User-2 (User-2#000) joined. (age=24.0 hours, risk=100)
00:00:00 @User-3 (User-3#000) joined. (age=2 days, risk=100)
00:00:00 @User-4 (User-4#000) joined. (age=365 days, risk=50)
00:00:00 @User-1 (User-1#000) joined. (age=5m 3s)
00:00:00 @User-2 (User-2#000) joined. (age=24h 20m 14s)
00:00:00 @User-3 (User-3#000) joined. (age=2d 4h 20m 1s)
00:00:00 @User-4 (User-4#000) joined. (age=365d)

As you can see, we also removed the old risk-rating system. The risk-score was used internally for Verification passthrough, which however switched to a more transparent minimum account age system. Initially the risk-rating was only exposed for debugging purposes, but was forgotten to be removed when the system went into production.