summaryrefslogtreecommitdiffstats
path: root/wp-includes/query.php
diff options
context:
space:
mode:
authordonncha <donncha@7be80a69-a1ef-0310-a953-fb0f7c49ff36>2007-03-23 17:46:02 +0000
committerdonncha <donncha@7be80a69-a1ef-0310-a953-fb0f7c49ff36>2007-03-23 17:46:02 +0000
commit2e96b99ceb195735a641e299f3209840cc101052 (patch)
tree374954833d10017ae7adb6a031d54fd0dc36f3a2 /wp-includes/query.php
parentbf6a271edebcceb76d6e378156e92fe72c1fbb18 (diff)
downloadwordpress-mu-2e96b99ceb195735a641e299f3209840cc101052.tar.gz
wordpress-mu-2e96b99ceb195735a641e299f3209840cc101052.tar.xz
wordpress-mu-2e96b99ceb195735a641e299f3209840cc101052.zip
Ryan casts an int and catches a fish, someone buy him a pint! merge to 5092
git-svn-id: http://svn.automattic.com/wordpress-mu/trunk@933 7be80a69-a1ef-0310-a953-fb0f7c49ff36
Diffstat (limited to 'wp-includes/query.php')
-rw-r--r--wp-includes/query.php14
1 files changed, 7 insertions, 7 deletions
diff --git a/wp-includes/query.php b/wp-includes/query.php
index 3432f74..26e1afc 100644
--- a/wp-includes/query.php
+++ b/wp-includes/query.php
@@ -587,7 +587,7 @@ class WP_Query {
if ( '' != $qv['pagename'] ) {
$this->queried_object =& get_page_by_path($qv['pagename']);
if ( !empty($this->queried_object) )
- $this->queried_object_id = $this->queried_object->ID;
+ $this->queried_object_id = (int) $this->queried_object->ID;
else
unset($this->queried_object);
@@ -1205,18 +1205,18 @@ class WP_Query {
$cat = $this->get('cat');
$category = &get_category($cat);
$this->queried_object = &$category;
- $this->queried_object_id = $cat;
+ $this->queried_object_id = (int) $cat;
} else if ($this->is_posts_page) {
$this->queried_object = & get_page(get_option('page_for_posts'));
- $this->queried_object_id = $this->queried_object->ID;
+ $this->queried_object_id = (int) $this->queried_object->ID;
} else if ($this->is_single) {
$this->queried_object = $this->post;
- $this->queried_object_id = $this->post->ID;
+ $this->queried_object_id = (int) $this->post->ID;
} else if ($this->is_page) {
$this->queried_object = $this->post;
- $this->queried_object_id = $this->post->ID;
+ $this->queried_object_id = (int) $this->post->ID;
} else if ($this->is_author) {
- $author_id = $this->get('author');
+ $author_id = (int) $this->get('author');
$author = get_userdata($author_id);
$this->queried_object = $author;
$this->queried_object_id = $author_id;
@@ -1285,7 +1285,7 @@ function setup_postdata($post) {
global $id, $postdata, $authordata, $day, $page, $pages, $multipage, $more, $numpages, $wp_query;
global $pagenow;
- $id = $post->ID;
+ $id = (int) $post->ID;
$authordata = get_userdata($post->post_author);