Rearranged package.name check to avoid crash
Buildozer would previously crash if a package name was '', as it checked for zero length *and* tried to check if the first character was a number.
This commit is contained in:
parent
feff9c2b23
commit
2800d516da
1 changed files with 3 additions and 3 deletions
|
@ -300,13 +300,13 @@ class Buildozer(object):
|
|||
adderror = errors.append
|
||||
if not get('app', 'title', ''):
|
||||
adderror('[app] "title" is missing')
|
||||
if not get('app', 'package.name', ''):
|
||||
adderror('[app] "package.name" is missing')
|
||||
if not get('app', 'source.dir', ''):
|
||||
adderror('[app] "source.dir" is missing')
|
||||
|
||||
package_name = get('app', 'package.name', '')
|
||||
if package_name[0] in map(str, range(10)):
|
||||
if not package_name:
|
||||
adderror('[app] "package.name" is missing')
|
||||
elif package_name[0] in map(str, range(10)):
|
||||
adderror('[app] "package.name" may not start with a number.')
|
||||
|
||||
version = get('app', 'version', '')
|
||||
|
|
Loading…
Reference in a new issue