Skip to content
This repository
Browse code

Reverting pull request #93 due to BC issues and mismatch between inte…

…nded behaviour and actual.

This pull request is being reverted due to two issues:
1) The pull request causes a backwards compatibility issue where a spurious warning would always be generated ("Table class not found in file")
2) The pull request states that the extension name should be used, instead the change actually uses the name of the model.

More details available on this platform mailing list post:

http://groups.google.com/group/joomla-dev-platform/msg/2f62f1352f1f09d7
  • Loading branch information...
commit b59de99cc90669f6b6f1ee93d7ba6efd7433900e 1 parent 28430d3
Sam Moffatt authored December 31, 2011
12  libraries/joomla/application/component/model.php
@@ -435,28 +435,18 @@ public function getState($property = null, $default = null)
435 435
 	 *
436 436
 	 * @since   11.1
437 437
 	 */
438  
-	public function getTable($name = '', $prefix = '', $options = array())
  438
+	public function getTable($name = '', $prefix = 'Table', $options = array())
439 439
 	{
440 440
 		if (empty($name))
441 441
 		{
442 442
 			$name = $this->getName();
443 443
 		}
444 444
 
445  
-		if (empty($prefix))
446  
-		{
447  
-			$prefix = $this->getName() . 'Table';
448  
-		}
449  
-
450 445
 		if ($table = $this->_createTable($name, $prefix, $options))
451 446
 		{
452 447
 			return $table;
453 448
 		}
454 449
 
455  
-		if ($table = $this->_createTable($name, 'Table', $options))
456  
-		{
457  
-			return $table;
458  
-		}
459  
-
460 450
 		JError::raiseError(0, JText::sprintf('JLIB_APPLICATION_ERROR_TABLE_NAME_NOT_SUPPORTED', $name));
461 451
 
462 452
 		return null;

0 notes on commit b59de99

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