LinkStackOrg / LinkStack

LinkStack - the ultimate solution for creating a personalized & professional profile page. Showcase all your important links in one place, forget the limitation of one link on social media. Set up your personal site on your own server with just a few clicks.
https://linkstack.org
GNU Affero General Public License v3.0
2.3k stars 235 forks source link

"Set user page as Home Page" option breaks redirect #369

Closed DunklerPhoenix closed 1 year ago

DunklerPhoenix commented 1 year ago

Platform: Debian Buster Server type: Docker. PHP version: 8.1

As I mentioned in this comment https://github.com/JulianPrieber/llc-docker/issues/38#issuecomment-1477976167 the option "Set user page as Home Page" breaks the redirects for me. If I set it back to "default" and use "disable_home_page" from the advanced editor instead everything works fine.

Did I misunderstood this option or is it a bit buggy?

JulianPrieber commented 1 year ago

I might be reading the context wrong here, but from what I'm understanding, the option is working exactly as intended.

Could you describe your issue in a bit more detail?

DunklerPhoenix commented 1 year ago

I understood the option like this:

How it works at the moment for me:

* "." because of githubs linking function

EDIT: From the description of the option it's not understandable that its making the userA page the only accessible site.

Set user page as Home Page
Set a user page as the home page. This will move the previous home page to example.com/home.
JulianPrieber commented 1 year ago

Yeah, you're right, I see your problem now. I'm not even sure if we can consider this a bug, we didn't really account for anyone doing this during development.

DunklerPhoenix commented 1 year ago

Hmm.. For what purpose is this option originally planned? Is it to disable Multiuser? So that only one user can be active in an instance?

At the moment it looks like a duplicate of the disable_home_page feature (from description). The disable_home_page is for my case exactly what I need and use now. Maybe it's just enough to clarify this option description a little bit.

JulianPrieber commented 1 year ago

Okay, maybe we're not thinking about the same issue? What do you exactly mean by "redirect"?

The disable_home_page setting just disables the home route regardless if it's / or /home. This can be used to completely get rid of the home page. This is intended to improve security or allows you to add a custom home page.

The option to set a user as the home page is exactly only designed for single user applications. Most people only have one user on the site, so this is an option most people use for their instances.

DunklerPhoenix commented 1 year ago

The option to set a user as the home page is exactly only designed for single user applications. Most people only have one user on the site, so this is an option most people use for their instances.

Ah okay. This is not really clear from the description. Maybe just add something like "This disables the usage of other profiles".

EDIT: Originally i thought that this option does replace the homepage with a userpage, but let the other pages still active.

EDIT2: You can't imagine how long I've been searching for the reason why other profiles didn't work anymore xD

JulianPrieber commented 1 year ago

Maybe just add something like "This disables the usage of other profiles". Originally i thought that this option does replace the homepage with a userpage, but let the other pages still active.

Well, during development, we only considered this single user mode. We didn't really think about anyone using single user mode with multiple users.

Not sure why you would want that, but I see no reason why this shouldn't be possible.

I'll look into restoring the use of multiple users with this kind of setup. I just looked into the source code, and I'm not sure how I would do something like this, but I'll try 👍

DunklerPhoenix commented 1 year ago

Not sure why you would want that

I use LittleLink for our sports club. The original home page can only be edited by admins and (i think) only by code. So I thought I create a new limited user, set his page as home and give this login out to someone who manage this "landing page" All other users are not affected by that.

For the moment I'm be torn between:

JulianPrieber commented 1 year ago

So, um, I have no idea what's causing this, but this actually used to work. If I roll back a commit, we can get this back to run properly.

JulianPrieber commented 1 year ago

Fixed in the latest beta