Browse files

BUGFIX Declaring has_many "Versions" relationship according to decora…

…ted class in Versioned->extraStatics()
  • Loading branch information...
1 parent 67cc18f commit 502131171bb61ecec38697111cd0c6a08f4e9e7f @chillu chillu committed Mar 23, 2011
Showing with 2 additions and 2 deletions.
  1. +2 −2 core/model/Versioned.php
View
4 core/model/Versioned.php
@@ -95,13 +95,13 @@ function __construct($stages) {
$this->liveStage = array_pop($stages);
}
- function extraStatics() {
+ function extraStatics($class) {
return array(
'db' => array(
'Version' => 'Int',
),
'has_many' => array(
- 'Versions' => 'SiteTree',
+ 'Versions' => $class,
)
);
}

0 comments on commit 5021311

Please sign in to comment.