瀏覽代碼

Merge pull request #3910 from adityahase/fix-maxlength-comparison

Make sure that max_length[0][0] is comparable with new_length
version-14
Rushabh Mehta 8 年之前
committed by GitHub
父節點
當前提交
1b9dd05481
共有 1 個文件被更改,包括 1 次插入1 次删除
  1. +1
    -1
      frappe/model/db_schema.py

+ 1
- 1
frappe/model/db_schema.py 查看文件

@@ -127,7 +127,7 @@ class DbTable:
else: else:
raise raise


if max_length and max_length[0][0] > new_length:
if max_length and max_length[0][0] and max_length[0][0] > new_length:
current_type = self.current_columns[col.fieldname]["type"] current_type = self.current_columns[col.fieldname]["type"]
current_length = re.findall('varchar\(([\d]+)\)', current_type) current_length = re.findall('varchar\(([\d]+)\)', current_type)
if not current_length: if not current_length:


Loading…
取消
儲存