From cb2788424d6953dd74813eaffbbb9f49c99527f0 Mon Sep 17 00:00:00 2001 From: Aaron Schulz Date: Wed, 30 Sep 2009 19:35:39 +0000 Subject: [PATCH] Added exists() function --- includes/filerepo/ArchivedFile.php | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/includes/filerepo/ArchivedFile.php b/includes/filerepo/ArchivedFile.php index a256f1f4eb..a2a65180ca 100644 --- a/includes/filerepo/ArchivedFile.php +++ b/includes/filerepo/ArchivedFile.php @@ -48,6 +48,7 @@ class ArchivedFile $this->timestamp = NULL; $this->deleted = 0; $this->dataLoaded = false; + $this->exists = false; if( is_object($title) ) { $this->title = $title; @@ -142,6 +143,7 @@ class ArchivedFile return; } $this->dataLoaded = true; + $this->exists = true; return true; } @@ -193,6 +195,11 @@ class ArchivedFile $this->load(); return $this->id; } + + public function exists() { + $this->load(); + return $this->exists; + } /** * Return the FileStore key -- 2.20.1