1
Fork 0
mirror of https://github.com/pds-nest/nest.git synced 2024-11-22 04:54:18 +00:00

🐛 Use commits a bit less liberally

This commit is contained in:
Steffo 2021-05-20 00:45:00 +02:00
parent 5e24c8f2e6
commit c6e00c1c5f
Signed by: steffo
GPG key ID: 6965406171929D01
2 changed files with 13 additions and 2 deletions

12
.idea/dataSources.xml Normal file
View file

@ -0,0 +1,12 @@
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="DataSourceManagerImpl" format="xml" multifile-model="true">
<data-source source="LOCAL" name="nest@zero.ryg.one" uuid="c18e9ee6-ec71-4ada-af3e-32b57a6e3f15">
<driver-ref>postgresql</driver-ref>
<synchronize>true</synchronize>
<jdbc-driver>org.postgresql.Driver</jdbc-driver>
<jdbc-url>jdbc:postgresql://zero.ryg.one:5432/nest</jdbc-url>
<working-dir>$ProjectFileDir$</working-dir>
</data-source>
</component>
</project>

View file

@ -203,7 +203,6 @@ def page_repository(rid):
for c in repository.conditions:
if c.id not in ids:
ext.session.delete(c)
ext.session.commit()
# Create brand new conditions
for c in request.json['conditions']:
if not c['id']:
@ -215,5 +214,5 @@ def page_repository(rid):
if type_ == ConditionType.hashtag:
content = hashtag_validator(content)
ext.session.add(Condition(type=type_, content=content, repository_id=rid))
ext.session.commit()
ext.session.commit()
return json_success(repository.to_json()), 200