Merge "Fix the displayed error message in V2 API"
This commit is contained in:
commit
05e894a3dc
@ -11,8 +11,6 @@
|
|||||||
# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
|
# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
|
||||||
# License for the specific language governing permissions and limitations
|
# License for the specific language governing permissions and limitations
|
||||||
# under the License.
|
# under the License.
|
||||||
import six
|
|
||||||
|
|
||||||
from designate.objects import base
|
from designate.objects import base
|
||||||
|
|
||||||
|
|
||||||
@ -33,7 +31,7 @@ class ValidationError(base.DesignateObject):
|
|||||||
|
|
||||||
e = cls()
|
e = cls()
|
||||||
e.path = list(getattr(js_error, 'releative_path', js_error.path))
|
e.path = list(getattr(js_error, 'releative_path', js_error.path))
|
||||||
e.message = six.text_type(js_error)
|
e.message = js_error.message
|
||||||
e.validator = js_error.validator
|
e.validator = js_error.validator
|
||||||
e.validator_value = js_error.validator_value
|
e.validator_value = js_error.validator_value
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user