Skip to content
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

Small Improvement - Make the file location configurable #28

Merged
merged 1 commit into from
Jul 16, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
@@ -1 +1,2 @@

composer.lock
vendor
4 changes: 3 additions & 1 deletion config.yml.dist
Original file line number Diff line number Diff line change
Expand Up @@ -12,4 +12,6 @@ defaults:
error: "There are errors in the form, please fix before trying to resubmit"
database:
# contenttype: feedback
fields: {}
fields: {}

file: config/extensions/boltforms.bolt.yml
2 changes: 1 addition & 1 deletion src/Controller/FormEditorController.php
Original file line number Diff line number Diff line change
Expand Up @@ -330,7 +330,7 @@ protected function simplifyFormData($data)
*/
protected function read()
{
$file = $this->app['resources']->getPath('config/extensions/boltforms.bolt.yml');
$file = $this->app['resources']->getPath($this->config['file']);
$yaml = file_get_contents($file);
$parser = new Parser();
$data = $parser->parse($yaml);
Expand Down