mirror of
https://github.com/getgrav/grav.git
synced 2026-06-14 19:11:53 +02:00
Added $grav->getVersion() or grav.version in twig to get the current Grav version [#3142]
This commit is contained in:
@@ -7,6 +7,7 @@
|
||||
* Improved session fixation handling in PHP 7.4+ (cannot fix it in PHP 7.3 due to PHP bug)
|
||||
* Added optional password/database attributes for redis in `system.yaml`
|
||||
* Added ability to filter enabled or disabled with bin/gpm index [#3187](https://github.com/getgrav/grav/pull/3187)
|
||||
* Added `$grav->getVersion()` or `grav.version` in twig to get the current Grav version [#3142](https://github.com/getgrav/grav/issues/3142)
|
||||
1. [](#bugfix)
|
||||
* Fixed CLI progressbar in `backup` and `security` commands to use styled output [#3198](https://github.com/getgrav/grav/issues/3198)
|
||||
* Fixed page save failing because of uploaded images [#3191](https://github.com/getgrav/grav/issues/3191)
|
||||
|
||||
@@ -162,6 +162,19 @@ class Grav extends Container
|
||||
return self::$instance;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get Grav version.
|
||||
*
|
||||
* @return string
|
||||
*/
|
||||
public function getVersion(): string
|
||||
{
|
||||
return GRAV_VERSION;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return bool
|
||||
*/
|
||||
public function isSetup(): bool
|
||||
{
|
||||
return isset($this->initialized['setup']);
|
||||
|
||||
Reference in New Issue
Block a user