Test Failed
Pull Request — master (#777)
by
unknown
03:44
created

savu.plugins.loaders.utils.my_safe_constructor   A

Complexity

Total Complexity 1

Size/Duplication

Total Lines 10
Duplicated Lines 0 %

Importance

Changes 0
Metric Value
eloc 5
dl 0
loc 10
rs 10
c 0
b 0
f 0
wmc 1

1 Method

Rating   Name   Duplication   Size   Complexity  
A MySafeConstructor.add_bool() 0 2 1
1
from yaml.constructor import SafeConstructor
2
3
4
# Create custom safe constructor class that inherits from SafeConstructor
5
class MySafeConstructor(SafeConstructor):
6
7
    # Create new method to handle boolean logic
8
    def add_bool(self, node):
9
        return self.construct_scalar(node)
10
11
12