Skip to content

Implement COPY verb support - #419

Merged
dmitrizagidulin merged 3 commits into
masterfrom
dz_copy_verb
Jul 26, 2016
Merged

dmitrizagidulin merged 3 commits into
masterfrom
dz_copy_verb

Conversation

@dmitrizagidulin

Copy link
Copy Markdown
Contributor

Implements issue solid/solid#49, adds support for an
HTTP Copy verb that allows importing an external resource to a given Solid destination.

Implements issue solid/solid#49, adds support for an
HTTP Copy verb that allows importing an external resource to a given Solid destination.
Comment thread lib/handlers/copy.js
* "Save an external resource to Solid" type apps.
* @method handler
*/
function handler (req, res, next) {

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

hey @dmitrizagidulin in order to make our life easy once we want to move to another type of store, we are abstracting all of the file system stuff into ldp.js. The way I see it is the following:

  1. File system
  2. LDP.copy
  3. HTTP Server handling

this copy.js should call LDP.copy (that will be implemented with fs calls and a callback_) and in the callback_ do the http handling (see get.js for example!)

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ah, I see what you're saying. Sure, I can refactor it to do that, np.

@dmitrizagidulin

Copy link
Copy Markdown
Contributor Author

@nicola - Refactored the code to call LDP copy, per your request.

@dmitrizagidulin

Copy link
Copy Markdown
Contributor Author

@nicola - I'll be merging this PR later this week. last chance to protest :)

@dmitrizagidulin
dmitrizagidulin merged commit b01c897 into master Jul 26, 2016
@dmitrizagidulin
dmitrizagidulin deleted the dz_copy_verb branch July 26, 2016 20:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants