Permalink
Browse files

added ability to refenerate eTag, if desired

  • Loading branch information...
fideloper committed Mar 29, 2013
1 parent 948641f commit 3721af2003206fea1bbeda8c564b9004e3ea37ad
Showing with 2 additions and 2 deletions.
  1. +2 −2 app/lib/Api/Resource/Eloquent/Resource.php
@@ -15,9 +15,9 @@ class Resource extends Model implements ResourceInterface {
*
* @return string ETag for resource
*/
public function getEtag()
public function getEtag($regen=false)
{
if ( $this->exists && $this->etag === false )
if ( $this->exists && ($this->etag === false || $regen === true) )
{
$this->etag = $this->generateEtag();
}

0 comments on commit 3721af2

Please sign in to comment.