From 44b05747782ce8643aaa4c928424a62aa92c0bae Mon Sep 17 00:00:00 2001 From: rimach Date: Tue, 7 Dec 2010 23:47:02 +0100 Subject: [PATCH] fix for missing title field --- openlp/plugins/songs/lib/songbeamerimport.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/openlp/plugins/songs/lib/songbeamerimport.py b/openlp/plugins/songs/lib/songbeamerimport.py index 8b07d2b32..0eb4927bc 100644 --- a/openlp/plugins/songs/lib/songbeamerimport.py +++ b/openlp/plugins/songs/lib/songbeamerimport.py @@ -99,13 +99,16 @@ class SongBeamerImport(SongImport): self.songData = infile.readlines() else: return False + self.title = self.file_name.split('.sng')[0] + self.read_verse = False for line in self.songData: line = line.strip() if line.startswith('#'): log.debug(u'find tag: %s' % line) if not self.parse_tags(line): return False - elif line.startswith('---'): + elif line.startswith('---') or \ + line.startswith('--'): log.debug(u'find ---') if len(self.current_verse) > 0: self.add_verse(self.current_verse,