Surplus_Up (2DU) пре 6 година
родитељ
комит
7a5a36181b
2 измењених фајлова са 3 додато и 3 уклоњено
  1. 2 2
      route/edit.py
  2. 1 1
      version.json

+ 2 - 2
route/edit.py

@@ -66,14 +66,14 @@ def edit_2(conn, name):
         new = curs.fetchall()
         if new:
             if flask.request.args.get('section', None):
-                data = re.sub('\n(?P<in>={1,6})', '<br>\g<in>', '\n' + re.sub('\r\n', '\n', new[0][0]) + '\n')
+                data = re.sub('\n(?P<in>={1,6})', '<br>\g<in>', html.escape('\n' + re.sub('\r\n', '\n', new[0][0]) + '\n'))
                 i = 0
 
                 while 1:
                     g_data = re.search('((?:<br>)(?:(?:(?!\n|<br>).)+)(?:\n*(?:(?:(?!<br>).)+\n*)+)?)', data)
                     if g_data:
                         if int(flask.request.args.get('section', '1')) - 1 == i:
-                            data = re.sub('<br>(?P<in>={1,6})', '\n\g<in>', g_data.groups()[0])
+                            data = html.unescape(re.sub('<br>(?P<in>={1,6})', '\n\g<in>', g_data.groups()[0]))
                             
                             break
                         else:

+ 1 - 1
version.json

@@ -1,6 +1,6 @@
 {
     "master" : {
-        "r_ver" : "v3.1.2-master-12",
+        "r_ver" : "v3.1.2-master-13",
         "c_ver" : "400001",
         "s_ver" : "2"
     }, "stable" : {