Merge pull request #588 from sharelatex/ja-restrict-front-widget

Add Dropbox test for Front widget too
This commit is contained in:
Alasdair Smith 2018-05-24 10:09:18 +01:00 committed by GitHub
commit 1849fcb70a

View file

@ -194,7 +194,7 @@ module.exports = ProjectController =
else
viewModel.showUserDetailsArea = false
paidUser = user.features?.github # use a heuristic for paid account
paidUser = user.features?.github and user.features?.dropbox # use a heuristic for paid account
freeUserProportion = 0.10
sampleFreeUser = parseInt(user._id.toString().slice(-2), 16) < freeUserProportion * 255
showFrontWidget = paidUser or sampleFreeUser