Trevor Buckner
ed30a1cd7d
Update other tests to pass
2025-02-13 16:20:59 -05:00
Trevor Buckner
94f478477d
Add test for missing meta:theme tag
2025-02-13 16:20:50 -05:00
Trevor Buckner
d8d672fada
Error message if chosen theme does not have "meta:theme" tag.
2025-02-13 15:51:06 -05:00
Trevor Buckner
f326d11232
Added input validation (allows Share ID or Share URL)
2025-02-13 00:05:30 -05:00
Trevor Buckner
c080e5b191
Add author to snippetBundle
2025-02-10 22:20:12 -05:00
David Bolack
94a431eec8
Update tests.
2025-01-07 22:28:12 -06:00
David Bolack
74122d9057
Display name of write in theme next to write-in
...
Clear user's active ThemeBundle when an incomplete/broken/invalid writein.
Needs theming help.
2025-01-07 22:11:01 -06:00
David Bolack
9745daf6e2
Merge branch 'master' into writeinBrewTheme
2024-12-20 15:19:06 -06:00
G.Ambatte
7a41a140fd
Merge branch 'master' into fixAdminAddedAsAuthor-#3952
2024-12-19 17:00:26 +13:00
Trevor Buckner
57467701d0
Fetch Google Brew if only stub requested but nothing found
...
/update/ requests only the stub for updating. But if no stub exists, we should fetch the full brew so we return *something*.
2024-12-18 23:00:01 -05:00
G.Ambatte
7a169cbd9e
Linter clean up
2024-12-19 16:20:28 +13:00
G.Ambatte
2dc8a8fbe9
Remove req.account from update request
2024-12-19 16:20:04 +13:00
Trevor Buckner
5f14f656ef
Logging
2024-12-18 17:23:38 -05:00
Trevor Buckner
6e8a0d7314
current user owns 0-author brew only if edit mode
...
Previous code was treating /share/ visits to google brews with no stub as visits by owner, thus using their own credentials to open the file instead of serviceaccount
2024-12-18 17:07:09 -05:00
Trevor Buckner
e61144beb8
Mark as owner if stub doesn't exist
...
Old Google Drive files without a stub have no author, so if no stub exists, consider the current user the owner.
2024-12-18 13:45:53 -05:00
Trevor Buckner
64b792c645
Fix case where no stub is found
...
When retrieving a Google Brew with no stub yet, if the user is not logged in or has expired credentials, we enter this error handler. However, the error message itself tries to send a list of authors.
If there was no stub, we crash here with a 500 error.
This adds conditional operator to any stub value so we can send the actual "not logged in" error in case of no stub.
2024-12-18 13:02:14 -05:00
Trevor Buckner
aee5b7a8cc
Require user to be logged in to change name
2024-12-18 12:14:08 -05:00
Trevor Buckner
bc14246fe7
fix import
2024-12-16 17:58:08 -05:00
Trevor Buckner
fcf985a115
Restore content-negotiation test
2024-12-16 17:42:06 -05:00
Trevor Buckner
a060fd123c
Merge branch 'master' into fixContentNegotiationTestFail-#3904
2024-12-16 17:39:34 -05:00
Víctor Losada Hernández
efa8f3fedf
remove unnecessary, cluttering logs
2024-12-16 22:13:14 +01:00
Víctor Losada Hernández
35be1e9b94
quickfix
2024-12-16 16:43:40 +01:00
Víctor Losada Hernández
a9275698fa
add comment to tell future me to remove logs when feature comes
2024-12-14 23:41:05 +01:00
Víctor Losada Hernández
99f2972079
fixes as asked
2024-12-14 23:34:12 +01:00
Víctor Losada Hernández
afc92c4545
fix check client version middleware to stop checking outside calls
2024-12-14 22:30:24 +01:00
Víctor Losada Hernández
b26526a2f1
lint and logging pass prepared for in server auth from this end
2024-12-14 22:24:52 +01:00
Víctor Losada Hernández
4f57f006ce
log cookies at auth middleware
2024-12-14 21:20:39 +01:00
Víctor Losada Hernández
666a94cd65
fix log
2024-12-14 21:15:16 +01:00
Víctor Losada Hernández
f0c094e9d8
logs to account middleware
2024-12-14 21:12:35 +01:00
Víctor Losada Hernández
a1c228b1d1
log req account
2024-12-14 21:01:38 +01:00
Víctor Losada Hernández
5e5c637c79
revert api catch on wrong route middleware
2024-12-14 20:59:51 +01:00
Víctor Losada Hernández
d573129f31
Merge branch 'master' of https://github.com/naturalcrit/homebrewery into re-author-brews-on-batch
2024-12-14 20:34:41 +01:00
David Bolack
47d7c69d1b
Merge branch 'master' into writeinBrewTheme
2024-12-10 23:20:48 -06:00
Víctor Losada Hernández
c29e1905bf
add localhost to allowed origins only if in local, also remake regex
2024-12-10 19:24:23 +01:00
Trevor Buckner
52d00b17a4
Merge branch 'master' into fixContentNegotiationTestFail-#3904
2024-12-10 11:58:05 -05:00
Víctor Losada Hernández
81f56ec91d
add heroku apps to cors
2024-12-09 18:59:48 +01:00
Trevor Buckner
c7d94b0779
Small cleanup
2024-12-08 23:59:27 -05:00
Trevor Buckner
9758797e2b
If user is owner, fetch Google Brew with user auth
...
Fixes the case where a user can see a Google Brew under their account (`listBrew()` uses their personal auth) but can't actually delete it (`getBrew()` only uses the serviceAccount). Occurs if a Google brew has lost its permissions somehow (set to "restricted", etc.) such that serviceAccount can no longer interact with it.
2024-12-08 23:42:14 -05:00
Trevor Buckner
74a7983757
Refactor and clean up "getBrew()"
...
Some redundant logic and sprawling formatting
2024-12-08 23:39:26 -05:00
Víctor Losada Hernández
4eb8abf1e7
Update CORS error message in app.js
2024-12-08 23:46:27 +01:00
Víctor Losada Hernández
23910cc94c
add cors policy and rename route
2024-12-08 23:43:32 +01:00
Víctor Losada Hernández
ef0ee78758
revert check client version changes
2024-12-08 23:43:06 +01:00
Víctor Losada Hernández
1b20c00842
log headers
2024-12-08 20:46:02 +01:00
Víctor Losada Hernández
db9212bd12
log req
2024-12-08 20:45:43 +01:00
Víctor Losada Hernández
31a22703c1
initial commit
2024-12-08 12:05:01 +01:00
David Bolack
8492c63f62
Merge branch 'master' into writeinBrewTheme
2024-12-04 20:40:14 -06:00
G.Ambatte
4b21538e3e
Add splitTextStyleAndMetadata tests
2024-12-02 17:14:45 +13:00
David Bolack
73c68fd11c
Functional first pass.
...
Needs:
- [ ] opinions on UI placement
- [ ] opinions on best choice for displaying a write-in based User Brew ( flip to writin box? Add to drop-down list? )
2024-11-27 21:35:29 -06:00
G.Ambatte
7a76c67038
Merge branch 'master' into fixContentNegotiationTestFail-#3904
2024-11-24 20:44:24 +13:00
Trevor Buckner
ebe8e1067c
Move babel config to separate file
...
Jest struggles to read all babel configurations if directly inside package.json.
This now allows us to install nanoid 5 and pass all tests with it.
2024-11-21 13:33:32 -05:00