Commit 0805dd06 authored by Nigel McNie's avatar Nigel McNie
Browse files

Fix the check for institution owner in View::owner_sql.

Institutions are strings, not numbers. Should've picked this up before.
parent c6930917
......@@ -1744,7 +1744,7 @@ class View {
* @return string
*/
private static function owner_sql($ownerobj) {
if (isset($ownerobj->institution) && is_numeric($ownerobj->group)) {
if (isset($ownerobj->institution)) {
return 'institution = ' . db_quote($ownerobj->institution);
}
if (isset($ownerobj->group) && is_numeric($ownerobj->group)) {
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment