Commit Graph

1266 Commits

Author SHA1 Message Date
Jason Williams
921f7dab5b Fix error in generating absolute URLs for RSS
Closes #4886
2015-02-03 21:10:06 +00:00
Hannah Wolfe
4eee52d142 Add cache invalidation header when updating tags
no issue
2015-01-27 23:44:31 +00:00
Hannah Wolfe
54c7d23b26 Merge pull request #4841 from jaswilli/frontend-match
Use path-match to match routes instead of Router
2015-01-26 21:28:35 +00:00
Hannah Wolfe
3c86f67fca Merge pull request #4831 from jaswilli/edit-user
Fix up users API so admin role can edit owner
2015-01-23 22:55:08 +01:00
Jason Williams
b06d2a619d Use path-match to match routes instead of Router
No Issue
- Use path-match instead of hacking up the Express.Router internals.
2015-01-22 19:21:47 +00:00
Jason Williams
786ec6be28 Format database-related error responses
Closes #4735
- Shows error message on client instead of "[object Object]".
- Server log shows error message instead of uknown error.
2015-01-21 18:09:09 +00:00
Jason Williams
0fc152b2ad Fix up users API so admin role can edit owner
No Issue.
- Make sure that a user with the Admin role can edit the Owner.
- Add test for behavior.
2015-01-20 21:34:24 +00:00
Jason Williams
7578d674ae Fixup finding user by role name
No Issue.
- Build up query object to lookup a user by the name of a role.  Return
  user with "roles" objects included.
- Add test for findOne by role.
2015-01-20 18:31:17 +00:00
Jason Williams
d5d7919d26 Assume datetime in import filename is UTC
No issue.
- Add missing catch handlers to async tests.
2015-01-18 21:20:51 +00:00
Jason Williams
1c07273f5a Update grunt-jscs dependency
No Issue
- grunt-jscs@1.2.0
- Clean up some instances of multiple spaces.
- Remove jscs:disable for regexes now that jscs better supports them.
2015-01-16 18:06:20 +00:00
Jason Williams
aee472eb65 Check all users when generating slug
No Issue
- Set 'status: all` when calling generateSlug from the user model
  so that all user slugs are checked for duplicates instead of
  only active users.
2015-01-16 06:56:53 +00:00
Matt Enlow
3982e0f871 Merge pull request #4804 from jaswilli/issue-4539
Connect Navigation page to live data
2015-01-14 15:45:04 -07:00
Jason Williams
a007ae1442 Connect Navigation page to live data
Closes #4539
2015-01-14 21:24:08 +00:00
Sebastian Gierlinger
023a37b074 Merge pull request #4772 from ekulabuhov/4262_NextPrevPostWIP
[API] Retrieve next and previous post
2015-01-14 10:32:07 +01:00
Eugene Kulabuhov
0e2709c42f [API] Retrieve next and previous post
closes #4262
- implementation based on #1545
- added integration test. Modified mocked posts because code requires published_at timestamps to be different.
- fixed 2 broken tests that depended on mocked posts to have "new Date()" as their timestamps
- added checks to only query db if next/previous post requested
2015-01-13 12:49:16 +00:00
Hannah Wolfe
0cb3483bc0 Merge pull request #4694 from PaulAdamDavis/navigation-ember
Navigation UI Ember Integration
2015-01-13 09:31:32 +00:00
Paul Adam Davis
6cc5a58b68 Navigation UI Ember Integration
Closes #4537

- Adds Navigation to the Settings menu
- Adds a `navigationUI` config flag (redirects if not an editor or author)
2015-01-11 20:04:01 +00:00
Jason Williams
be462d8d94 Merge pull request #4781 from ErisDS/has-tag-fix
Fix has helper tag matching
2015-01-11 13:01:55 -06:00
Hannah Wolfe
3f34162fd9 Fix has helper tag matching
fixes #4780
2015-01-09 21:52:23 +00:00
Hannah Wolfe
283deb2461 Fix email sending fail when blog title has a comma
no issue

- We send emails from Blog Title <ghost@blog-url.com>, but it should be from "Blog Title" <ghost@blog-url.com>
- It worked fine without quotes unless you have a comma in your Blog Title in which case different mail systems get confused in different ways
2015-01-09 21:34:24 +00:00
Jason Williams
7501b4478d Merge pull request #4692 from ErisDS/markdown-importer
Add markdown file handler to importer
2015-01-09 14:44:46 -06:00
Hannah Wolfe
fbdabce086 Add markdown file handler to importer
closes #4691

- adds a file handler for markdown file (.md and .markdown)
- handles titles and featured images
- gets status, date, and slug from the filename
- has a test suite
2015-01-09 20:04:56 +00:00
Jeremiah Hoyet
bbe3ceb025 Fixed issue where Gravatars with rating higher than G would cause a 404 error.
closes #4770
- Check for Gravatar now allows the highest rating for images
- Defaults to silhouette in the event a user deletes their Gravatar
- Allows highest rating for Gravatars (x), since Ghost should have no opinion on image ratings.
2015-01-08 19:34:28 -05:00
Hannah Wolfe
1f22d8c28c Move tag management from behind config/labs flags
issue #4248

- tag management is ready for release, this takes the training wheels off :)
- remove config flag
- remove labs checkbox and related code
2015-01-06 18:56:42 +00:00
Jason Williams
7f753acff1 Merge pull request #4752 from ErisDS/importer-updates
Image Importer Improvements
2015-01-05 10:39:35 -06:00
Jason Williams
05877124ae Remove unneeded promises and fix tests 2015-01-04 21:05:31 +00:00
Jason Williams
7c7dbb911c Merge pull request #4750 from ErisDS/labs-thing
Labs page checkboxes
2015-01-04 13:44:47 -06:00
Hannah Wolfe
3310dba9ea Merge pull request #4738 from jaswilli/socket-perms
Allow socket permissions to be set from config
2015-01-03 19:41:27 +00:00
Hannah Wolfe
add4c6b078 Image Importer Improvements
ref #4608, #4609, #4690

- fix errors with cleaning up files
- improve handling of base directories, and introduce a simple valid format for zips (must contain importable files or folders, and may contain up to one base directory)
- vastly improve test coverage
2015-01-02 22:54:40 +00:00
Paul Adam Davis
cc6f698053 Start of labs
issue #4409
2015-01-02 15:58:36 +00:00
Jason Friedrich
bc74c89e76 Update excerpt helper to properly filter HTML footnotes
closes #4741
- updated regexp to properly filter out footnotes without removing too much text
- happened only when a link was used before a footnote
- old regexp was too 'greedy' and removed regular link together with the footnote
- new regexp uses a more specific <a> tag
2015-01-01 06:45:06 +01:00
Jason Williams
6c1287c3a2 Allow socket permissions to be set from config
Closes #4478
2014-12-31 15:28:04 +00:00
Jason Williams
0dc0d37888 Change url and image into synchronous helpers
Closes #3961
2014-12-29 18:44:15 +00:00
Jason Williams
f6736049c3 Fix up HTTP API handler
No Issue
- Add Location header for tags.
- Ensure Location header has trailing slash.
- Remove unnecessary promises/async.
2014-12-28 05:27:29 +00:00
Jason Williams
d59f873aec Update dependencies
No Issue
- bluebird@2.4.2
- body-parser@1.10.0
- busboy@0.2.9
- connect-slashes@1.3.0 (remove base path option which is no
  longer needed)
- fs-extra@0.13.0
- glob@0.4.2
- passport@0.2.1
- passport-oauth2-client-password@0.1.2
- grunt-jscs@1.1.0
2014-12-25 00:22:45 +00:00
Jason Williams
2c66430dba Merge pull request #4690 from ErisDS/image-importer
Add support for importing images
2014-12-24 17:08:13 -06:00
Hannah Wolfe
a54b5c4af1 Merge pull request #4698 from jaswilli/tag-dup-slugs
Run tag add operations in sequence
2014-12-22 10:00:05 +00:00
Hannah Wolfe
7f4539e67e Merge pull request #4693 from cobbspur/metatags
Updated meta helpers to use tag meta data if present
2014-12-22 09:56:11 +00:00
Jason Williams
633cf1385a Run tag add operations in sequence
Closes #4697
- Run tag add operations in sequence instead of in parallel
  since generateSlug will hand out duplicate slugs until one of
  them is committed to the database.
- Add test.
- Misc cleanup of method parameter names and jshint hints.
2014-12-22 00:41:10 +00:00
cobbspur
32059812a9 Updated meta helpers to use tag meta data if present
No issue

- Tag Meta title and description override default response
- Tag Meta title present on all pages
- Tag Meta description available only on first page
 - Updates tests
2014-12-21 11:39:49 +00:00
Hannah Wolfe
ba3d4b3689 Add support for importing images
closes #4608, #4609

- image handler loads in any image files & figures out where they'll get stored
- image importer has a preprocessor which replaces image paths in
  pertinent spots of post, tag and user models
- image importer stores images, keeping the path where it makes sense
- basic test for the preprocessor
2014-12-21 01:58:35 +00:00
Jason Williams
591fa349aa Finish up post count support in tags API
Refs #4521
- Handle 'include' query param in tags API.
- Add post_count support when fetching a tag with findOne.
- Remove post_count from options.include after processing.
- Extra database query no longer used to fetch post_count.
2014-12-19 21:46:34 +00:00
Hannah Wolfe
6af0b83b7c Merge pull request #4670 from jaswilli/model-opt
Optimize model class methods
2014-12-19 21:19:01 +00:00
Hannah Wolfe
e6227e7a24 Merge pull request #4674 from delgermurun/post-sort
Add 'id' to post sort fields. So there is no longer equally sorted posts.
2014-12-19 21:05:45 +00:00
Jason Williams
5c6d45f258 Optimize model class methods
No Issue
- Reorder promise chains to defer database queries until they
  are needed.
- Execute database queries that are not dependent on each other in
  parallel instead of sequentially.
- Reduce the number of variables used to hold state across multiple
  promise blocks.
- Do not go async unless necessary.
2014-12-19 00:54:22 +00:00
Hannah Wolfe
8ceb896e96 Merge pull request #4654 from ekulabuhov/4521_TagPostCount
[API] Return post count for each tag
2014-12-19 00:17:36 +00:00
Eugene Kulabuhov
539accf69f [API] Return post count for each tag
closes #4521
- if '?include=post_count' present, query db for tag/post_count information
  and append it to returned JSON
- fixed linter errors
- added integration test
- parsing to int as knex (or PostGres driver) is returning bigint as strings
- iterating through a smaller collection to avoid exception
2014-12-18 23:54:18 +00:00
Hannah Wolfe
3c9273ed37 Data importer improvements and fixes
refs #4605, #4479

- Removes versioning from the importer
- Fixes an issue with SQLITE errors not being thrown properly for posts
- Ensures that posts have a created_at date
- Makes sure that the API wrapper is properly handled
2014-12-18 19:50:53 +00:00
Jason Williams
68df133d65 Merge pull request #4646 from ErisDS/importer-refactor
Refactor importer with tests
2014-12-18 13:24:11 -06:00
Hannah Wolfe
1b37ba5753 Merge pull request #4676 from jaswilli/pg-update
Update pg package and convert data to correct type
2014-12-18 16:50:01 +00:00