diff rhodecode/controllers/files.py @ 1484:1db451a44504 beta

fixed small issues with adding new filenodes
author Marcin Kuzminski <marcin@python-works.com>
date Thu, 22 Sep 2011 15:03:12 +0300
parents 7b67b0dcad6d
children 269905fac50a
line wrap: on
line diff
--- a/rhodecode/controllers/files.py	Thu Sep 22 04:33:29 2011 +0300
+++ b/rhodecode/controllers/files.py	Thu Sep 22 15:03:12 2011 +0300
@@ -317,6 +317,10 @@
                 h.flash(_('No content'), category='warning')
                 return redirect(url('changeset_home', repo_name=c.repo_name,
                                     revision='tip'))
+            if not filename:
+                h.flash(_('No filename'), category='warning')
+                return redirect(url('changeset_home', repo_name=c.repo_name,
+                                    revision='tip'))                
 
             try:
                 self.scm_model.create_node(repo=c.rhodecode_repo,