def clean_expired_user_attempts(attempt_time: datetime = None) -> int:
if settings.AXES_COOLOFF_TIME is None:<EOL><INDENT>log.debug('<STR_LIT>')<EOL>return <NUM_LIT:0><EOL><DEDENT>threshold = get_cool_off_threshold(attempt_time)<EOL>count, _ = AccessAttempt.objects.filter(attempt_time__lt=threshold).delete()<EOL>log.info('<STR_LIT>', count, threshold)<EOL>return count<EOL>
Clean expired user attempts from the database.