Permalink
Browse files

MINOR Don't assume existence of cms/ folder in LeftAndMain->CMSVersio…

…n() (regression from earlier code)
  • Loading branch information...
1 parent c2f7bf4 commit 85a898e1d594a859a77c109e867c6de0c10f69c2 @chillu chillu committed Apr 9, 2012
Showing with 1 addition and 1 deletion.
  1. +1 −1 admin/code/LeftAndMain.php
@@ -1172,7 +1172,7 @@ public function PreviewLink() {
* @return string
*/
public function CMSVersion() {
- if(file_exists(CMS_PATH . '/silverstripe_version')) {
+ if(defined('CMS_PATH') && file_exists(CMS_PATH . '/silverstripe_version')) {
$sapphireVersion = file_get_contents(CMS_PATH . '/silverstripe_version');
} else {
$sapphireVersion = file_get_contents(SAPPHIRE_PATH . '/silverstripe_version');

0 comments on commit 85a898e

Please sign in to comment.