mirror of
https://github.com/nextcloud/android.git
synced 2024-11-23 05:35:39 +03:00
Replace OwnCloudClient instances
Signed-off-by: ZetaTom <70907959+ZetaTom@users.noreply.github.com>
This commit is contained in:
parent
1a7847bbb5
commit
0afeffc1bb
1 changed files with 3 additions and 2 deletions
|
@ -282,12 +282,13 @@ class ChooseTemplateDialogFragment : DialogFragment(), View.OnClickListener, Tem
|
||||||
override fun doInBackground(vararg params: Void): String {
|
override fun doInBackground(vararg params: Void): String {
|
||||||
return try {
|
return try {
|
||||||
val client = clientFactory!!.create(user)
|
val client = clientFactory!!.create(user)
|
||||||
|
val nextcloudClient = clientFactory.createNextcloudClient(user)
|
||||||
val result = DirectEditingCreateFileRemoteOperation(
|
val result = DirectEditingCreateFileRemoteOperation(
|
||||||
path,
|
path,
|
||||||
creator!!.editor,
|
creator!!.editor,
|
||||||
creator.id,
|
creator.id,
|
||||||
template.title
|
template.title
|
||||||
).execute(client)
|
).execute(nextcloudClient)
|
||||||
if (!result.isSuccess) {
|
if (!result.isSuccess) {
|
||||||
return ""
|
return ""
|
||||||
}
|
}
|
||||||
|
@ -352,7 +353,7 @@ class ChooseTemplateDialogFragment : DialogFragment(), View.OnClickListener, Tem
|
||||||
|
|
||||||
override fun doInBackground(vararg voids: Void): TemplateList {
|
override fun doInBackground(vararg voids: Void): TemplateList {
|
||||||
return try {
|
return try {
|
||||||
val client = clientFactory!!.create(user)
|
val client = clientFactory!!.createNextcloudClient(user)
|
||||||
val result = DirectEditingObtainListOfTemplatesRemoteOperation(
|
val result = DirectEditingObtainListOfTemplatesRemoteOperation(
|
||||||
creator!!.editor,
|
creator!!.editor,
|
||||||
creator.id
|
creator.id
|
||||||
|
|
Loading…
Reference in a new issue