Skip to content

fix(GDPR): Do not track local project paths #3592

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 3 commits into from
May 17, 2018

Conversation

rosen-vladimirov
Copy link
Contributor

@rosen-vladimirov rosen-vladimirov commented May 16, 2018

Do not track paths to projects when local template is used. Instead track localTemplate_<name from template's package.json or dirname>.
Also fix the prompter for emails as we need to show information how to unsubscribe from the newsletter.
Add tests for the behavior.

PR Checklist

Fixes #3595

@rosen-vladimirov rosen-vladimirov self-assigned this May 16, 2018
@rosen-vladimirov rosen-vladimirov force-pushed the vladimirov/gdpr-v1 branch 2 times, most recently from 23136f1 to f536725 Compare May 16, 2018 21:53
Do not track paths to projects when local template is used. Instead track `localTemplate_<name from template's package.json or dirname>`.
Also fix the prompter for emails as we need to show information how to unsubscribe from the newsletter.
Add tests for the behavior.
@@ -46,5 +46,21 @@ export class ProjectTemplatesService implements IProjectTemplatesService {
this.$logger.trace(`Using NativeScript verified template: ${templateName} with version ${version}.`);
return this.$npmInstallationManager.install(templateName, projectDir, { version: version, dependencyType: "save" });
}

private getTemplateNameToBeTracked(templateName: string, realTemplatePath: string): string {
Copy link
Contributor

@Fatme Fatme May 17, 2018

Choose a reason for hiding this comment

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

Not sure, but maybe the whole code should be in try { } catch { }. In case something fails here we don't want to stop the command execution.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Nice idea, I've added the try-catch and test for this case.

Copy link
Contributor

@Fatme Fatme left a comment

Choose a reason for hiding this comment

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

After green build and handling my comment

@rosen-vladimirov rosen-vladimirov merged commit c538c67 into release May 17, 2018
@rosen-vladimirov rosen-vladimirov deleted the vladimirov/gdpr-v1 branch May 17, 2018 09:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants