Explorar el Código

:octocat: +Version::__toString()

codemasher hace 4 años
padre
commit
f294c3a6d6
Se han modificado 1 ficheros con 7 adiciones y 0 borrados
  1. 7 0
      src/Common/Version.php

+ 7 - 0
src/Common/Version.php

@@ -272,6 +272,13 @@ final class Version{
 		$this->version = $version;
 	}
 
+	/**
+	 * returns the current version number as string
+	 */
+	public function __toString():string{
+		return (string)$this->version;
+	}
+
 	/**
 	 * returns the current version number
 	 */