Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Z
Zope
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
Zope
Commits
ee2687ed
Commit
ee2687ed
authored
Aug 08, 2001
by
Andreas Jung
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
"extra" parameter of addIndex has not been passed to the TextIndex
constructor
parent
76fddebc
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
11 additions
and
1 deletion
+11
-1
lib/python/Products/ZCatalog/ZCatalog.py
lib/python/Products/ZCatalog/ZCatalog.py
+11
-1
No files found.
lib/python/Products/ZCatalog/ZCatalog.py
View file @
ee2687ed
...
...
@@ -802,6 +802,7 @@ class ZCatalog(Folder, Persistent, Implicit):
def
addIndex
(
self
,
name
,
type
,
extra
=
None
):
# Convert the type by finding an appropriate product which supports
# this interface by that name. Bleah
...
...
@@ -823,7 +824,16 @@ class ZCatalog(Folder, Persistent, Implicit):
if
base
is
None
:
raise
ValueError
,
"Index type %s does not support addIndex"
%
type
index
=
base
(
name
,
self
)
# This code is somewhat lame but every index type has its own function
# signature *sigh* and there is no common way to pass additional parameters
# to the constructor. The suggested way for new index types is to use
# an "extra" record.
if
'extra'
in
base
.
__init__
.
func_code
.
co_varnames
:
index
=
apply
(
base
,(
name
,),
{
"extra"
:
extra
})
else
:
index
=
base
(
name
,
self
)
self
.
_catalog
.
addIndex
(
name
,
index
)
...
...
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