so the only thing that was different from your recommendation was packageActions, which i was intentionally grouping with the $scope.packageAction declaration for easy reference.