function unsubscribeAll() {

        if (socketMessage.session) {

            var confirmDeleteStream = function (response, project) {
                if (response.status === 'ok') {
                    project.subscribed = false;
                } else {
                    Y.log("delete " + response.status + " for " + project.title + ' ' + JSON.stringify(response));
                }
            };

            var i, l;
            for (/*var*/i = 0, l = Y.postmile.gpostmile.projects.length; i < l; ++i) {
                var project = Y.postmile.gpostmile.projects[i];
                if (project.subscribed) {
                    deleteJson('/stream/' + socketMessage.session + '/project/' + project.id, null, confirmDeleteStream, project);
                    project.subscribed = false; // presume this works (we'd not do anything differently anyways)
                }
            }
        }
    }
// unsubscribe to all projects with delete
unsubscribe to all projects with delete
unsubscribe to all projects with delete
function unsubscribeAll() {
        if (socketMessage.session) {
            var confirmDeleteStream = function (response, project) {
                if (response.status === 'ok') {
                    project.subscribed = false;
                } else {
                    Y.log("delete " + response.status + " for " + project.title + ' ' + JSON.stringify(response));
                }
            };
            var i, l;
            for (i = 0, l = Y.postmile.gpostmile.projects.length; i < l; ++i) {
                var project = Y.postmile.gpostmile.projects[i];
                if (project.subscribed) {
                    deleteJson('/stream/' + socketMessage.session + '/project/' + project.id, null, confirmDeleteStream, project);
                    project.subscribed = false; 
                }
            }
        }
    }
function unsubscribeAll ( ) { if ( socketMessage . session ) { var confirmDeleteStream = function ( response , project ) { if ( response . status === 'ok' ) { project . subscribed = false ; } else { Y . log ( "delete " + response . status + " for " + project . title + ' ' + JSON . stringify ( response ) ) ; } } ; var i , l ; for ( i = 0 , l = Y . postmile . gpostmile . projects . length ; i < l ; ++ i ) { var project = Y . postmile . gpostmile . projects [ i ] ; if ( project . subscribed ) { deleteJson ( '/stream/' + socketMessage . session + '/project/' + project . id , null , confirmDeleteStream , project ) ; project . subscribed = false ; } } } }
unsubscribe to all projects with delete
unsubscribe to all projects with delete
/*var*/ // presume this works (we'd not do anything differently anyways)