summaryrefslogtreecommitdiff
path: root/core/helpers
diff options
context:
space:
mode:
Diffstat (limited to 'core/helpers')
-rw-r--r--core/helpers/task.php18
1 files changed, 2 insertions, 16 deletions
diff --git a/core/helpers/task.php b/core/helpers/task.php
index 816a5288..d5cc7c4e 100644
--- a/core/helpers/task.php
+++ b/core/helpers/task.php
@@ -21,7 +21,7 @@ class task_Core {
/**
* Get all available tasks
*/
- static function get_task_definitions($type=array("admin", "both")) {
+ static function get_definitions($type) {
$tasks = array();
foreach (module::installed() as $module_name => $module_info) {
$class_name = "{$module_name}_task";
@@ -38,7 +38,7 @@ class task_Core {
}
static function create($task_callback) {
- $task_definitions = self::get_task_definitions(array("admin", "general", "both"));
+ $task_definitions = self::get_definitions(array("admin", "general", "both"));
$task = ORM::factory("task");
$task->callback = $task_callback;
@@ -84,18 +84,4 @@ class task_Core {
return $task;
}
-
- static function success($task, $location=null) {
- $result = array("result" => "success", "task" => $task->as_array());
- if (!empty($location)) {
- $result["location"] = $location;
- }
- return json_encode($result);
- }
-
- static function in_progress($task) {
- return json_encode(
- array("result" => "in_progress",
- "task" => $task->as_array()));
- }
} \ No newline at end of file