Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

classes/Options_V2: Update the permalink when changing the course slug #955

Open
wants to merge 1 commit into
base: dev
Choose a base branch
from

Conversation

bernhardkaindl
Copy link

This feature is already released
But it was initially not working for existing courses, See bug #576.

This code is originally from @shewa12's PR about it.

Renaming the course base slug of existing courses is missing. They stay with their old slug!!!

These changes (of this Pull Request) which @shewa12 made, may do that, right?

These changes have not been merged yet!!!

	array(
		'key'         => 'course_permalink_base',
		'type'        => 'text',
		'label'       => __( 'Course Slug', 'tutor' ),
		'placeholder' => __( 'Course Slug', 'tutor' ),
		'label_title' => '',
		'default'     => tutor()->course_post_type,
		'desc'        => __( 'Update the permalink when changing the course slug', 'tutor' ),
	),

The same renaming would also have to be done when the lesson base slug changes, which is also not done.

Also, fold a variable that was only used once.

Co-authored-by: Bernhard Kaindl <[email protected]>
@bernhardkaindl bernhardkaindl changed the base branch from master to dev August 7, 2024 13:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants