<commit_before>exports.post = function(request, response) {
    // Use "request.service" to access features of your mobile service, e.g.:
    //   var tables = request.service.tables;
    //   var push = request.service.push;

    response.send(statusCodes.OK, { message : 'Hello World!' });
};

exports.get = function(request, response) {
    response.send(statusCodes.OK, { message : 'Hello World!' });
};<commit_msg>Committing update from request /api/scmvfs/service/api/completeall.js<commit_after>exports.post = function(request, response) {
    // Use "request.service" to access features of your mobile service, e.g.:
    var tables = request.service.tables;
    //   var push = request.service.push;
    var user = request.user;
    var todoItem = tables.table('TodoItem');
    
    todoItem.where({
        userId: user.userId, 
        complete: false
    }).read({
        success: completeAll
    });
    
    function completeAll(items){
        items.forEach(function(item){
            item.complete = true;
            todoItem.update(item);
        });
    }
    
    response.send(statusCodes.OK);
};
{'fraction_non_alphanumeric': 0.13416815742397137, 'fraction_numerical': 0.0, 'mean_word_length': 2.705298013245033, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '7119434', 'n_tokens_mistral': 324, 'n_tokens_neox': 328, 'n_words': 74}