(user, options = {})
| 971 | // Function meant for "me" |
| 972 | |
| 973 | spy (user, options = {}) { |
| 974 | user = user.id || user // User instance, user ID, email or username |
| 975 | options.url = '/auth/spy' |
| 976 | options.type = 'POST' |
| 977 | if (options.data == null) { options.data = {} } |
| 978 | options.data.user = user |
| 979 | this.clearUserSpecificLocalStorage() |
| 980 | return this.fetch(options) |
| 981 | } |
| 982 | |
| 983 | stopSpying (options = {}) { |
| 984 | options.url = '/auth/stop-spying' |
no test coverage detected