Skip to content

Commit fe22c00

Browse files
authored
Deprecation: show the project slug/link correctly on email (#10432)
Small fixes to generate the URL correctly.
1 parent 8012b88 commit fe22c00

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

readthedocs/projects/tasks/utils.py

+3-2
Original file line numberDiff line numberDiff line change
@@ -288,10 +288,11 @@ def deprecated_config_file_used_notification():
288288
user_projects = AdminPermission.projects(user, admin=True).values_list(
289289
"slug", flat=True
290290
)
291-
user_projects = list(set(user_projects) & projects)
291+
user_projects_slugs = list(set(user_projects) & projects)
292+
user_projects = Project.objects.filter(slug__in=user_projects_slugs)
292293

293294
# Create slug string for onsite notification
294-
user_project_slugs = ", ".join(user_projects[:5])
295+
user_project_slugs = ", ".join(user_projects_slugs[:5])
295296
if len(user_projects) > 5:
296297
user_project_slugs += " and others..."
297298

0 commit comments

Comments
 (0)