Remove trailing newlines introduced from new/edit page for http functions
This commit is contained in:
@@ -37,8 +37,7 @@
|
||||
|
||||
</div>
|
||||
|
||||
<div id="editor" class="relative rounded-lg shadow-lg p-4 mb-4">{{ script }}
|
||||
</div>
|
||||
<div id="editor" class="relative rounded-lg shadow-lg p-4 mb-4">{{ script }}</div>
|
||||
|
||||
<button
|
||||
class="bg-transparent hover:bg-blue-500 text-blue-700 font-semibold hover:text-white py-2 px-4 border border-blue-500 hover:border-transparent rounded flex"
|
||||
@@ -141,7 +140,7 @@
|
||||
|
||||
document.querySelector('#add-http-function').addEventListener('click', () => {
|
||||
let name = document.querySelector('#function-name').value;
|
||||
let script_content = editor.getValue();
|
||||
let script_content = editor.getValue().trim();
|
||||
|
||||
fetch("{{ url_for('create_http_function') }}", {
|
||||
method: 'POST',
|
||||
|
||||
Reference in New Issue
Block a user