Commit b4455aaf authored by Benjamin Neff's avatar Benjamin Neff Committed by Dennis Schubert

Fix 20160906225138_fix_photos_share_visibilities.rb for postgres

Turns out that postgres can't handle "0" as boolean, but mysql can
handle "false".

closes #7115#pullrequestreview-699342
parent ffb44226
......@@ -21,7 +21,7 @@ class FixPhotosShareVisibilities < ActiveRecord::Migration
"INNER JOIN posts ON posts.guid = photos.status_message_guid AND posts.type = 'StatusMessage' " \
"LEFT OUTER JOIN share_visibilities ON share_visibilities.shareable_id = photos.id " \
"INNER JOIN share_visibilities AS post_visibility ON post_visibility.shareable_id = posts.id " \
"WHERE photos.public = 0 AND share_visibilities.shareable_id IS NULL " \
"WHERE photos.public = false AND share_visibilities.shareable_id IS NULL " \
"AND post_visibility.shareable_type = 'Post'"
end
......
Markdown is supported
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