Skip to content
This repository
Browse code

BUGFIX: Ensure that extensio arugments are passed when temporarily in…

…stantiating for setting up statics.
  • Loading branch information...
commit 1aefc0aa94ab36b023308846007d5f5178682565 1 parent c41ff29
Sam Minnée authored June 11, 2012

Showing 1 changed file with 1 addition and 1 deletion. Show diff stats Hide diff stats

  1. 2  model/DataExtension.php
2  model/DataExtension.php
@@ -38,7 +38,7 @@ static function add_to_class($class, $extensionClass, $args = null) {
38 38
 			$extraStaticsMethod = 'extraStatics';
39 39
 		}
40 40
 
41  
-		$statics = singleton($extensionClass)->$extraStaticsMethod($class, $extensionClass);
  41
+		$statics = Injector::inst()->get($extensionClass, true, $args)->$extraStaticsMethod($class, $extensionClass);
42 42
 
43 43
 		if ($statics) {
44 44
 			Deprecation::notice('3.1.0', "$extraStaticsMethod deprecated. Just define statics on your extension, or use add_to_class");

0 notes on commit 1aefc0a

Please sign in to comment.
Something went wrong with that request. Please try again.