mirror of
https://github.com/EDCD/EDMarketConnector.git
synced 2025-06-04 17:41:18 +03:00
ChangeLog: Document back/forwards compatible config.appversion
This commit is contained in:
parent
00f4e00dc8
commit
c2f4e4fbda
11
ChangeLog.md
11
ChangeLog.md
@ -216,6 +216,17 @@ Plugin Developers
|
|||||||
* `config.appversion()` is now a function that returns a `semantic_version.Version`.
|
* `config.appversion()` is now a function that returns a `semantic_version.Version`.
|
||||||
In contexts where you're expecting a string this should mostly
|
In contexts where you're expecting a string this should mostly
|
||||||
just work. If needs be wrap it in `str()`.
|
just work. If needs be wrap it in `str()`.
|
||||||
|
|
||||||
|
For backwards compatibility with pre-5.0.0 you can use:
|
||||||
|
|
||||||
|
```python
|
||||||
|
from config import appversion
|
||||||
|
|
||||||
|
if callable(appversion):
|
||||||
|
edmc_version = appversion()
|
||||||
|
else:
|
||||||
|
edmc_version = appversion
|
||||||
|
```
|
||||||
|
|
||||||
* Example plugin
|
* Example plugin
|
||||||
[plugintest](https://github.com/EDCD/EDMarketConnector/tree/main/docs/examples/plugintest)
|
[plugintest](https://github.com/EDCD/EDMarketConnector/tree/main/docs/examples/plugintest)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user