Merge branch '97-if-i-create-a-new-room-with-an-image-remove-image-does-not-work' into 'dev'

Resolve "If I create a new room with an image - remove image does not work"

Closes #97

See merge request sa4-2020/the-sanmarinoes/frontend!121
This commit is contained in:
Claudio Maggioni 2020-05-04 18:01:50 +02:00
commit b26162415c
2 changed files with 1450 additions and 953 deletions

View file

@ -26,7 +26,7 @@ class RoomModal extends Component {
this.addRoomModal = this.addRoomModal.bind(this);
this.updateIcon = this.updateIcon.bind(this);
this.removeImage = this.removeImage.bind(this);
this.unsetImage = this.unsetImage.bind(this);
}
get initialState() {
@ -38,13 +38,9 @@ class RoomModal extends Component {
};
}
removeImage(e) {
unsetImage = (e) => {
e.preventDefault();
this.setState(
update(this.state, {
image: { $set: null },
})
);
this.setState({ ...this.state, img: "" });
}
setInitialState() {

File diff suppressed because it is too large Load diff