Browse Source

Fixed checking for git user existing being opposite

tags/3.0.0
Teknikode 2 years ago
parent
commit
e89e62f248
1 changed files with 5 additions and 7 deletions
  1. 5
    7
      Teknik/Areas/User/Utility/UserHelper.cs

+ 5
- 7
Teknik/Areas/User/Utility/UserHelper.cs View File

@@ -906,8 +906,6 @@ If you recieved this email and you did not reset your password, you can ignore t
// If Email Server is enabled
if (config.EmailConfig.Enabled)
{
// Query the Email DB

// We need to check the actual git database
MysqlDatabase mySQL = new MysqlDatabase(config.EmailConfig.CounterDatabase.Server, config.EmailConfig.CounterDatabase.Database, config.EmailConfig.CounterDatabase.Username, config.EmailConfig.CounterDatabase.Password, config.EmailConfig.CounterDatabase.Port);
string sql = @"INSERT INTO mailcounter.counts (qname, lastdate, qlimit, count) VALUES ({1}, NOW(), {0}, 0)
@@ -976,7 +974,7 @@ If you recieved this email and you did not reset your password, you can ignore t
if (config.GitConfig.Enabled)
{
// Git user exists?
if (UserGitExists(config, username))
if (!UserGitExists(config, username))
{
throw new Exception($"Git User '{username}' does not exist.");
}
@@ -1041,7 +1039,7 @@ If you recieved this email and you did not reset your password, you can ignore t
if (config.GitConfig.Enabled)
{
// Git user exists?
if (UserGitExists(config, username))
if (!UserGitExists(config, username))
{
throw new Exception($"Git User '{username}' does not exist.");
}
@@ -1072,7 +1070,7 @@ If you recieved this email and you did not reset your password, you can ignore t
if (config.GitConfig.Enabled)
{
// Git user exists?
if (UserGitExists(config, username))
if (!UserGitExists(config, username))
{
throw new Exception($"Git User '{username}' does not exist.");
}
@@ -1135,7 +1133,7 @@ If you recieved this email and you did not reset your password, you can ignore t
if (config.GitConfig.Enabled)
{
// Git user exists?
if (UserGitExists(config, username))
if (!UserGitExists(config, username))
{
throw new Exception($"Git User '{username}' does not exist.");
}
@@ -1168,7 +1166,7 @@ If you recieved this email and you did not reset your password, you can ignore t
if (config.GitConfig.Enabled)
{
// Git user exists?
if (UserGitExists(config, username))
if (!UserGitExists(config, username))
{
throw new Exception($"Git User '{username}' does not exist.");
}

Loading…
Cancel
Save