You are an expert in writing code in many different languages. Your goal is to perform code completion for the following code, keeping in mind the rest of the code and the file meta data.
    Metadata details:
    filename: wiki.go
    path of file: ./repos/studygolang/internal/logic
    
    the code of the file until where you have to start completion: // Copyright 2016 The StudyGolang Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
// http://studygolang.com
// Author:polaris	polaris@studygolang.com

package logic

import (
	"errors"
	"net/url"
	"strconv"
	"strings"

	. "github.com/studygolang/studygolang/db"
	"github.com/studygolang/studygolang/internal/model"

	"golang.org/x/net/context"

	"github.com/polaris1119/goutils"
	"github.com/polaris1119/logger"
	"github.com/polaris1119/set"
)

type WikiLogic struct{}

var DefaultWiki = WikiLogic{}

// Create 创建一个wiki页面
func (WikiLogic) Create(ctx context.Context, me *model.Me, form url.Values) error {
	objLog := GetLogger(ctx)

	wiki := &model.Wiki{}
	er
    
func (self WikiLogic) Modify(ctx context.Context, me *model.Me, form url.Values) error {
	objLog := GetLogger(ctx)

	id := goutils.MustInt(form.Get("id"))
	wiki := self.FindById(ctx, id)
	if !CanEdit(me, wiki) {
		return errors.New("没有权限")
	}

	if wiki.Uid != me.Uid {
		hasExists := false
		cuids := strings.Split(wiki.Cuid, ",")
		for _, cuid := range cuids {
			if me.Uid == goutils.MustInt(cuid) {
				hasExists = true
				break
			}
		}

		if !hasExists {
			cuids = append(cuids, strconv.Itoa(me.Uid))
			wiki.Cuid = strings.Join(cuids, ",")
		}
	}

	wiki.Title = form.Get("title")
	wiki.Content = form.Get("content")

	_, err := MasterDB.ID(id).Update(wiki)
	if err != nil {
		objLog.Errorf("更新wiki 【%d】 信息失败：%s\n", id, err)
		return err
	}

	go modifyObservable.NotifyObservers(me.Uid, model.TypeWiki, wiki.Id)

	return nil
}