(reader)
| 246 | } |
| 247 | }); |
| 248 | function readDirectory(reader) { |
| 249 | reader.readEntries(function (entries) { |
| 250 | if (entries.length) { |
| 251 | queue += entries.length; |
| 252 | each(entries, function(entry) { |
| 253 | if (entry.isFile) { |
| 254 | var fullPath = entry.fullPath; |
| 255 | entry.file(function (file) { |
| 256 | fileReadSuccess(file, fullPath); |
| 257 | }, readError); |
| 258 | } else if (entry.isDirectory) { |
| 259 | readDirectory(entry.createReader()); |
| 260 | } |
| 261 | }); |
| 262 | readDirectory(reader); |
| 263 | } else { |
| 264 | decrement(); |
| 265 | } |
| 266 | }, readError); |
| 267 | } |
| 268 | function fileReadSuccess(file, fullPath) { |
| 269 | // relative path should not start with "/" |
| 270 | file.relativePath = fullPath.substring(1); |
no test coverage detected
searching dependent graphs…