Use the backup to solve the residual after deleting the code.
This commit is contained in:
@@ -427,6 +427,8 @@ public class EditorView extends FrameLayout implements CodeCompletionBar.OnHintC
|
|||||||
}
|
}
|
||||||
|
|
||||||
public Observable<String> save() {
|
public Observable<String> save() {
|
||||||
|
String path = mUri.getPath();
|
||||||
|
PFiles.move(path, path + ".bak");
|
||||||
return Observable.just(mEditor.getText())
|
return Observable.just(mEditor.getText())
|
||||||
.observeOn(Schedulers.io())
|
.observeOn(Schedulers.io())
|
||||||
.doOnNext(s -> PFiles.write(getContext().getContentResolver().openOutputStream(mUri), s))
|
.doOnNext(s -> PFiles.write(getContext().getContentResolver().openOutputStream(mUri), s))
|
||||||
|
|||||||
Reference in New Issue
Block a user