Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
Gelencsér Szabolcs
/
cloud
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Members
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit
70b50134
authored
Mar 04, 2014
by
Kálmán Viktor
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
storage: fix Disk.create_empty activity problem
parent
d4737b15
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
7 deletions
+3
-7
circle/storage/models.py
+3
-7
No files found.
circle/storage/models.py
View file @
70b50134
...
@@ -287,13 +287,9 @@ class Disk(AclBase, TimeStampedModel):
...
@@ -287,13 +287,9 @@ class Disk(AclBase, TimeStampedModel):
:return: Disk object without a real image, to be .deploy()ed later.
:return: Disk object without a real image, to be .deploy()ed later.
"""
"""
with
disk_activity
(
code_suffix
=
"create"
,
user
=
user
)
as
act
:
disk
=
cls
(
**
kwargs
)
disk
=
cls
.
objects
.
create
(
**
kwargs
)
if
disk
.
filename
is
None
:
with
disk_activity
(
code_suffix
=
"create"
,
user
=
user
,
disk
=
disk
):
disk
.
generate_filename
()
disk
.
save
()
act
.
disk
=
disk
act
.
save
()
if
instance
:
if
instance
:
instance
.
disks
.
add
(
disk
)
instance
.
disks
.
add
(
disk
)
return
disk
return
disk
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment