Commit graph

561 commits

Author SHA1 Message Date
Akinwale Ariwodola
bdf7639bb2 Added version call to lbry.js since proxy polyfill still doesn't work properly 2018-04-21 21:40:54 +01:00
Igor Gassmann
38b239ddb6 Merge branch 'master' into cleanup 2018-04-21 12:43:43 -04:00
Sean Yesmunt
b786f1cfb7 remove modal/snack constants 2018-04-19 14:59:08 -04:00
Sean Yesmunt
c278824b3d update doNotify and add doHideNotification 2018-04-19 14:55:37 -04:00
ProfessorDey
40ae42c5f6
Simplify Media Identification Function
Rebased from LBRY/lbry-app PR# 1304 with corrections requested by Codacy (Though may still complain regarding spacing).

This just makes the code for finding documents a lot easier. the regex patterns and the media type are converted into keypairs, [regex, mediatype] which is then reduced to a single value, which will either be the original filename if there are no matching extensions, or the mediatype. So long as the mediatype does not contain an extension at the end of the string, this system should work far more simply.

This will also allow for easier addition of new extensions to the function, so long as they all follow the same pattern for the regex:
^ = Start of string
.+ = 1 or more characters of any type
. = A literal dot
(a|b|c) = A list of ORed extensions within a capture group '( )'
$ = End of string, so it is certain this is the actual extension of the filename

Won't be hard to add things like Archives, Executables, etc with just a single extra line now.
2018-04-19 17:59:24 +00:00
Sean Yesmunt
006963322e fix: check that claim exists before checking value 2018-04-05 11:45:17 -04:00
Igor Gassmann
c7d65ad378 fix: linting errors 2018-04-05 11:27:29 -04:00
akinwale
6418b5a9f2
Common components refactor (#1) 2018-04-05 03:57:29 +01:00
Akinwale Ariwodola
57e5b4a086 added lbryapi.js and removed electron-specific code from lbry.js 2018-01-15 19:06:44 +01:00
Akinwale Ariwodola
e127e3c38d updated index for cost_info reducer 2018-01-11 13:12:37 +01:00
Akinwale Ariwodola
cf9b0cfdaf Initial commit 2018-01-11 12:54:20 +01:00