Error in function username in home.php

Post Reply
herrheinrich
Jr. Bludit
Posts: 8
Joined: Fri Aug 10, 2018 10:24 am

Hi

Running Bludit 2.3.4 in a fresh install, based on Plesk with PHP 7.1.20,
everything is running smooth so far.
After a fresh install of bayerbergs theme blogr I catched following error:

Code: Select all

Fatal error: Uncaught Error: Call to a member function username() on 
booolean in PATH/home.php:121 
This is the same error others already mentioned in this forum.

I found out that I changed the name of the admin user to Anothername directly in
bl-content/databases/users.php, this is causing the error. Switching back to „admin" everything is tunning fine.

In 2.3.4 PRO this error doesnt occur.
User avatar
Edi
Site Admin
Posts: 3121
Joined: Sun Aug 09, 2015 5:01 pm
Location: Zurich
Has thanked: 54 times
Been thanked: 77 times
Contact:

herrheinrich wrote: Fri Aug 10, 2018 2:01 pm This is the same error others already mentioned in this forum.
Which thread or threads do you mean?
I found out that I changed the name of the admin user to Anothername directly in
bl-content/databases/users.php, this is causing the error. Switching back to „admin" everything is tunning fine.
The name or the role? There has always to be at least one user with the role "admin".
Clickwork - Websites mit Bludit | Planet Bludit - Tipps und Snippets
User avatar
diego
Site Admin
Posts: 773
Joined: Sat May 16, 2015 2:53 pm
Been thanked: 1 time
Contact:

There are not different between Bludit and Bludit PRO in the core code.

I do not recommend changing the user admin, just disable it and create a new one, https://docs.bludit.com/en/security/disable-admin-user

Regards
herrheinrich
Jr. Bludit
Posts: 8
Joined: Fri Aug 10, 2018 10:24 am

Many thanks Edi & Diego for your answers. Both helped me.

Just to mention what I've done:
I replaced the word "admin" by another name (e.g. "jack") in file bl-content/databases/users.php.

As Diego suggested I created a new user and disabled admin. Now everything runs smooth.
Post Reply