Passed
Pull Request — master (#1)
by
unknown
02:17
created

LocalizedTextField   A

Complexity

Total Complexity 1

Size/Duplication

Total Lines 10
Duplicated Lines 0 %

Test Coverage

Coverage 40%

Importance

Changes 1
Bugs 0 Features 0
Metric Value
c 1
b 0
f 0
dl 0
loc 10
rs 10
ccs 2
cts 5
cp 0.4
wmc 1

1 Method

Rating   Name   Duplication   Size   Complexity  
A formfield() 0 9 1
1 1
from ..forms import LocalizedTextFieldForm
2 1
from .localized_char_field import LocalizedCharField
3
4
5 1
class LocalizedTextField(LocalizedCharField):
6 1
    def formfield(self, **kwargs):
7
        """Gets the form field associated with this field."""
8
9
        defaults = {
10
            'form_class': LocalizedTextFieldForm
11
        }
12
13
        defaults.update(kwargs)
14
        return super().formfield(**defaults)
15