Skip to content

Commit 044d94f

Browse files
committed
[FIX] runbot correction in validation.py
1 parent bc33dad commit 044d94f

File tree

3 files changed

+10
-15
lines changed

3 files changed

+10
-15
lines changed

awesome_gallery/static/src/gallery_controller.js

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,6 @@ import { useService } from "@web/core/utils/hooks";
55
import { standardViewProps } from "@web/views/standard_view_props";
66
import { Layout } from "@web/search/layout";
77
import { usePager } from "@web/search/pager_hook";
8-
import { useTooltip } from "@web/core/tooltip/tooltip_hook";
98

109
export class GalleryController extends Component {
1110
static template = "awesome_gallery.GalleryController";

awesome_gallery/validation.py

Lines changed: 10 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
# -*- coding: utf-8 -*-
21
import logging
32
import os
43

@@ -11,21 +10,18 @@
1110

1211
_gallery_validator = None
1312

13+
1414
@view_validation.validate('gallery')
1515
def schema_viewname(arch, **kwargs):
16-
""" Check the gallery view against its schema
17-
18-
:type arch: etree._Element
19-
"""
20-
global _gallery_validator
16+
global _gallery_validator
2117

22-
if _gallery_validator is None:
23-
with misc.file_open(os.path.join('awesome_gallery', 'rng', 'gallery_view.rng')) as f:
24-
_gallery_validator = etree.RelaxNG(etree.parse(f))
18+
if _gallery_validator is None:
19+
with misc.file_open(os.path.join('awesome_gallery', 'rng', 'gallery_view.rng')) as f:
20+
_gallery_validator = etree.RelaxNG(etree.parse(f))
2521

26-
if _gallery_validator.validate(arch):
27-
return True
22+
if _gallery_validator.validate(arch):
23+
return True
2824

29-
for error in _gallery_validator.error_log:
30-
_logger.error(ustr(error))
31-
return False
25+
for error in _gallery_validator.error_log:
26+
_logger.error(ustr(error))
27+
return False

awesome_kanban/static/src/kanban_controller.js

Whitespace-only changes.

0 commit comments

Comments
 (0)