Skip to content

Instantly share code, notes, and snippets.

View catorda's full-sized avatar

Catrina Torda catorda

View GitHub Profile
@catorda
catorda / aho_privacy_policy
Created September 28, 2019 22:15
AHO Privacy Policy
## Privacy Policy
Catrina Torda built the AHO App app as a Free app. This SERVICE is provided by Catrina Torda at no cost and is intended for use as is.
This page is used to inform visitors regarding my policies with the collection, use, and disclosure of Personal Information if anyone decided to use my Service.
If you choose to use my Service, then you agree to the collection and use of information in relation to this policy. The Personal Information that I collect is used for providing and improving the Service. I will not use or share your information with anyone except as described in this Privacy Policy.
The terms used in this Privacy Policy have the same meanings as in our Terms and Conditions, which is accessible at AHO App unless otherwise defined in this Privacy Policy.
function updateGoals(user, goal, callback) {
// Check if mainGoal has an ID
// If no id was found, create a new mainGoal
var goalId = goal._id;
if(!goalId) {
// Before creating the goal, check if user has goal with that name
Goal.findOne({name: goal.name, owner: user.id}, function(err, g){
if(err) return callback(err);
if(g) return callback(new Error('There is another goal with that name'));