aboutsummaryrefslogtreecommitdiff
path: root/mod/reportedcontent
diff options
context:
space:
mode:
authorewinslow <ewinslow@36083f99-b078-4883-b0ff-0f9b5a30f544>2010-10-30 21:32:54 +0000
committerewinslow <ewinslow@36083f99-b078-4883-b0ff-0f9b5a30f544>2010-10-30 21:32:54 +0000
commitf49fdf4e1c80fe5bde922c25bdd6ca0e2c912ddb (patch)
treeeb2fdb272ba76e83af60378d05602a26a265be36 /mod/reportedcontent
parent9ebb6cff1cf22d4fb708c4ced37604c6cf5bbfae (diff)
downloadelgg-f49fdf4e1c80fe5bde922c25bdd6ca0e2c912ddb.tar.gz
elgg-f49fdf4e1c80fe5bde922c25bdd6ca0e2c912ddb.tar.bz2
Refs #2124: Using get_loggedin_user functions instead of $vars['user'], $_SESSION['user'], etc.
git-svn-id: http://code.elgg.org/elgg/trunk@7139 36083f99-b078-4883-b0ff-0f9b5a30f544
Diffstat (limited to 'mod/reportedcontent')
-rw-r--r--mod/reportedcontent/actions/add.php2
-rw-r--r--mod/reportedcontent/add.php2
-rw-r--r--mod/reportedcontent/views/default/reportedcontent/form.php2
3 files changed, 3 insertions, 3 deletions
diff --git a/mod/reportedcontent/actions/add.php b/mod/reportedcontent/actions/add.php
index 6e86c4cf6..0611f7402 100644
--- a/mod/reportedcontent/actions/add.php
+++ b/mod/reportedcontent/actions/add.php
@@ -15,7 +15,7 @@
$report = new ElggObject;
$report->subtype = "reported_content";
- $report->owner_guid = $_SESSION['user']->getGUID();
+ $report->owner_guid = get_loggedin_userid();
$report->title = $title;
$report->address = $address;
$report->description = $description;
diff --git a/mod/reportedcontent/add.php b/mod/reportedcontent/add.php
index fd90e0f5e..9b6032d04 100644
--- a/mod/reportedcontent/add.php
+++ b/mod/reportedcontent/add.php
@@ -14,7 +14,7 @@ gatekeeper();
// Get the current page's owner
$page_owner = page_owner_entity();
if ($page_owner === false || is_null($page_owner)) {
- $page_owner = $_SESSION['user'];
+ $page_owner = get_loggedin_user();
set_page_owner($page_owner->getGUID());
}
diff --git a/mod/reportedcontent/views/default/reportedcontent/form.php b/mod/reportedcontent/views/default/reportedcontent/form.php
index e21a4408b..fe4287888 100644
--- a/mod/reportedcontent/views/default/reportedcontent/form.php
+++ b/mod/reportedcontent/views/default/reportedcontent/form.php
@@ -15,7 +15,7 @@ if ($address == "previous") {
$tags = array();
$access_id = ACCESS_PRIVATE;
$shares = array();
-$owner = $vars['user'];
+$owner = get_loggedin_user();
?>
<form action="<?php echo $vars['url']; ?>action/reportedcontent/add" method="post" class="margin_top">