diff --git a/mod/home.php b/mod/home.php
index a60e96ccb..d796052ad 100644
--- a/mod/home.php
+++ b/mod/home.php
@@ -19,7 +19,7 @@ function home_content(&$a) {
$a->page['footer'] .= "
";
$o .= 'Welcome' . ((x($a->config,'sitename')) ? " to {$a->config['sitename']}" : "" ) . '
';
- $o .= login(1);
+ $o .= login(($a->config['register_html'] == REGISTER_CLOSED) ? 0 : 1);
return $o;
diff --git a/mod/login.php b/mod/login.php
index 4ee4e1fa0..ba232a943 100644
--- a/mod/login.php
+++ b/mod/login.php
@@ -4,5 +4,5 @@
function login_content(&$a) {
// return login($a->config['register_enabled']);
- return login(($a->config['register_policy'] == REGISTER_CLOSED) ? 0 : 1);
+ return login(($a->config['register_policy'] == REGISTER_CLOSED) ? false : true);
}
\ No newline at end of file