Created Pages Throw 404

If a CS-Cart page is created with the admin and "Registered users" is the only usergroup box checked under Availability, shouldn't guests be prompted to login rather than get a 404 error when they land on the page?

If a user is already logged in and lands on the page, it displays as it is supposed to.

If this is by design, is there a way to display the login form rather than the 404 error? This is very confusing to users.

it is designed so. To change this behaviour, please open the following file

app/controllers/frontend/pages.php

and replace:

    if (empty($page) || ($page[‘status’] == ‘D’ && !$preview)) {
return array(CONTROLLER_STATUS_NO_PAGE);
}
with
    if (empty($page) || ($page[‘status’] == ‘D’ && !$preview)) {
return array(
CONTROLLER_STATUS_REDIRECT,
‘auth.login_form?return_url=’ . urlencode(Registry::get(‘config.current_url’))
);
}