mirror of https://github.com/perkeep/perkeep.git
app/scancab: fix filename regexp for updateLoop
This commit removes two slashes from the filename regexp which prevented successful matching of files to upload to the scanningcabinet. I assume that the slashes were just a leftover from the port from Perl. Change-Id: I6712c9c5464d7ecd748fb352a993afbc759edbec
This commit is contained in:
parent
92b866d819
commit
6393fc4275
app/scanningcabinet/scancab
|
@ -225,7 +225,7 @@ func (a imageNameByTime) Swap(i, j int) { a[i], a[j] = a[j], a[i] }
|
|||
func (a imageNameByTime) Less(i, j int) bool { return a[i].nanoTime < a[j].nanoTime }
|
||||
|
||||
func uploadLoop() {
|
||||
toUploadPattern := regexp.MustCompile(`/^image-.+-unx(\d+)\.(png|jpg)$/`)
|
||||
toUploadPattern := regexp.MustCompile(`^image-.+-unx(\d+)\.(png|jpg)$`)
|
||||
if err := os.Chdir(queueDir); err != nil {
|
||||
log.Fatalf("Could not chdir to queue directory %v: %v", queueDir, err)
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue