From 32f3334b5cb270201c553f16e407c5567ea7cccd Mon Sep 17 00:00:00 2001 From: Daniel Friesel Date: Mon, 4 Mar 2019 19:36:11 +0100 Subject: [PATCH] forbid the user name 'dev' --- index.pl | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/index.pl b/index.pl index e7e46dc..1b3a661 100755 --- a/index.pl +++ b/index.pl @@ -992,7 +992,7 @@ post '/x/register' => sub { return; } - if ( $self->check_if_user_name_exists($user) ) { + if ( $self->check_if_user_name_exists($user) or $user eq 'dev' ) { $self->render( 'register', invalid => 'user_collision' ); return; } @@ -1036,9 +1036,12 @@ post '/x/register' => sub { ], body => encode( 'utf-8', $body ), ); - sendmail($reg_mail); - $self->render( 'login', from => 'register' ); + # TODO re-enable once remaining registration code is complete + #sendmail($reg_mail); + #$self->render( 'login', from => 'register' ); + + $self->render( 'register', invalid => 'not implemented yet' ); }; get '/*station' => sub {