Sanitize google drive IDs to remove URL hash etc.
This commit is contained in:
parent
46a738b7f4
commit
1797e11b43
3 changed files with 8 additions and 3 deletions
|
|
@ -467,6 +467,11 @@ var Getters = {
|
|||
|
||||
/* google docs */
|
||||
gd: function (id, callback) {
|
||||
if (!/^[a-zA-Z0-9_-]+$/.test(id)) {
|
||||
callback("Invalid ID: " + id);
|
||||
return;
|
||||
}
|
||||
|
||||
var data = {
|
||||
type: "googledrive",
|
||||
kind: "single",
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue