@@ -820,11 +820,11 class User < Principal | |||||
820 | Message.where(['author_id = ?', id]).update_all(['author_id = ?', substitute.id]) |
|
820 | Message.where(['author_id = ?', id]).update_all(['author_id = ?', substitute.id]) | |
821 | News.where(['author_id = ?', id]).update_all(['author_id = ?', substitute.id]) |
|
821 | News.where(['author_id = ?', id]).update_all(['author_id = ?', substitute.id]) | |
822 | # Remove private queries and keep public ones |
|
822 | # Remove private queries and keep public ones | |
823 |
::Query. |
|
823 | ::Query.where('user_id = ? AND visibility = ?', id, ::Query::VISIBILITY_PRIVATE).delete_all | |
824 | ::Query.where(['user_id = ?', id]).update_all(['user_id = ?', substitute.id]) |
|
824 | ::Query.where(['user_id = ?', id]).update_all(['user_id = ?', substitute.id]) | |
825 | TimeEntry.where(['user_id = ?', id]).update_all(['user_id = ?', substitute.id]) |
|
825 | TimeEntry.where(['user_id = ?', id]).update_all(['user_id = ?', substitute.id]) | |
826 |
Token. |
|
826 | Token.where('user_id = ?', id).delete_all | |
827 |
Watcher. |
|
827 | Watcher.where('user_id = ?', id).delete_all | |
828 | WikiContent.where(['author_id = ?', id]).update_all(['author_id = ?', substitute.id]) |
|
828 | WikiContent.where(['author_id = ?', id]).update_all(['author_id = ?', substitute.id]) | |
829 | WikiContent::Version.where(['author_id = ?', id]).update_all(['author_id = ?', substitute.id]) |
|
829 | WikiContent::Version.where(['author_id = ?', id]).update_all(['author_id = ?', substitute.id]) | |
830 | end |
|
830 | end |
General Comments 0
You need to be logged in to leave comments.
Login now