| Conditions | 2 |
| Total Lines | 14 |
| Lines | 0 |
| Ratio | 0 % |
| Tests | 0 |
| CRAP Score | 6 |
| 1 | from plugin.core.environment import Environment |
||
| 19 | @classmethod |
||
| 20 | def increment(cls): |
||
| 21 | prefix = Environment.dict['session.prefix'] |
||
| 22 | |||
| 23 | if prefix is None: |
||
| 24 | prefix = 1 |
||
| 25 | else: |
||
| 26 | prefix += 1 |
||
| 27 | |||
| 28 | # Update session prefix |
||
| 29 | cls._set(prefix) |
||
| 30 | |||
| 31 | log.debug('Incremented session prefix to %r', prefix) |
||
| 32 | return prefix |
||
| 33 | |||
| 41 |