gasdigitalltd
Chevereto Member
many users are getting internal server error after update to latest version
apache log error
exception 'CHV\\ListingException' with message 'SQLSTATE[42S22]: Column not found: 1054 Unknown column 'chv_images.image_nsfw' in 'where clause'' in /xxx/c/app/lib/classes/class.listing.php:349\
seems to be a problem with hardcoded db table name at class.listing.php line 237
$this->where .= '(' . $nsfw_off_clause . ' OR (chv_images.image_nsfw = 1 AND chv_images.image_user_id = ' . $this->requester['id'] . ')) AND ';
should be
$this->where .= '(' . $nsfw_off_clause . ' OR ('.$tables['images'].'.image_nsfw = 1 AND '.$tables['images'].'.image_user_id = ' . $this->requester['id'] . ')) AND ';
apache log error
exception 'CHV\\ListingException' with message 'SQLSTATE[42S22]: Column not found: 1054 Unknown column 'chv_images.image_nsfw' in 'where clause'' in /xxx/c/app/lib/classes/class.listing.php:349\
seems to be a problem with hardcoded db table name at class.listing.php line 237
$this->where .= '(' . $nsfw_off_clause . ' OR (chv_images.image_nsfw = 1 AND chv_images.image_user_id = ' . $this->requester['id'] . ')) AND ';
should be
$this->where .= '(' . $nsfw_off_clause . ' OR ('.$tables['images'].'.image_nsfw = 1 AND '.$tables['images'].'.image_user_id = ' . $this->requester['id'] . ')) AND ';