Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
line 63 seems wrong:
$result = db_query('SELECT name, title, type, visibility FROM {profile_fields} WHERE visibility = %d ORDER BY weight', PROFILE_PUBLIC, PROFILE_PUBLIC_LISTING);
PROFILE PUBLIC_LISTING should have an "S" at the end; also there is only one variable substitution in the above query. I believe it should be:
$result = db_query('SELECT name, title, type, visibility FROM {profile_fields} WHERE visibility = %d OR visibility = %d ORDER BY weight', PROFILE_PUBLIC,PROFILE_PUBLIC_LISTINGS);
Comment | File | Size | Author |
---|---|---|---|
#4 | profile_view_query_1.patch | 1.31 KB | nedjo |
#3 | profile_view_query_0.patch | 1.31 KB | Robin Monks |
#2 | profile_view_query.patch | 1.11 KB | Robin Monks |
Comments
Comment #1
samo CreditAttribution: samo commentedthis is still active in HEAD and is a very easy fix.
anyone?
Comment #2
Robin Monks CreditAttribution: Robin Monks commentedCorrects issue.
Tested to WORK on HEAD.
Robin
Comment #3
Robin Monks CreditAttribution: Robin Monks commentedAlso fixes someone else spelling mistake futher down (thanks to Malthus for noticing this).
Robin
Comment #4
nedjoThanks for catching these issues (they're from my previous patch). There should be a space after the comma (
PROFILE_PUBLIC, PROFILE_PUBLIC_LISTINGS
), which I've added to the patch.Comment #5
Robin Monks CreditAttribution: Robin Monks commentedComment #6
Dries CreditAttribution: Dries commentedCommitted alternative solution.
Comment #7
(not verified) CreditAttribution: commentedComment #8
(not verified) CreditAttribution: commentedComment #9
(not verified) CreditAttribution: commentedComment #10
(not verified) CreditAttribution: commentedComment #11
(not verified) CreditAttribution: commented