|
|
@@ -151,7 +151,9 @@ module.exports = ProjectController =
|
|
|
ProjectGetter.findAllUsersProjects user_id, 'name lastUpdated publicAccesLevel archived owner_ref tokens', cb
|
|
|
v1Projects: (cb) ->
|
|
|
Modules.hooks.fire "findAllV1Projects", user_id, (error, projects = []) ->
|
|
|
- cb error, projects[0] # hooks.fire returns an array of results, only need first
|
|
|
+ if error? and error.message == 'No V1 connection'
|
|
|
+ return cb(null, projects: [], tags: [], noConnection: true)
|
|
|
+ return cb(error, projects[0]) # hooks.fire returns an array of results, only need first
|
|
|
hasSubscription: (cb)->
|
|
|
LimitationsManager.userHasSubscriptionOrIsGroupMember currentUser, cb
|
|
|
user: (cb) ->
|
|
|
@@ -179,6 +181,7 @@ module.exports = ProjectController =
|
|
|
user: user
|
|
|
hasSubscription: results.hasSubscription[0]
|
|
|
isShowingV1Projects: results.v1Projects?
|
|
|
+ noV1Connection: results.v1Projects?.noConnection
|
|
|
}
|
|
|
|
|
|
if Settings?.algolia?.app_id? and Settings?.algolia?.read_only_api_key?
|